diff --git a/knockout.mapping.js b/knockout.mapping.js index 2ac4a3d..b284670 100644 --- a/knockout.mapping.js +++ b/knockout.mapping.js @@ -690,8 +690,11 @@ }; function canHaveProperties(object) { + if (object === null) { + return false; + } var type = exports.getType(object); - return ((type === "object") || (type === "array")) && (object !== null); + return (type === "object") || (type === "array"); } // Based on the parentName, this creates a fully classified name of a property