diff options
Diffstat (limited to 'node_modules/jquery/src/data/var/acceptData.js')
-rw-r--r-- | node_modules/jquery/src/data/var/acceptData.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/node_modules/jquery/src/data/var/acceptData.js b/node_modules/jquery/src/data/var/acceptData.js new file mode 100644 index 0000000000..6e15af1278 --- /dev/null +++ b/node_modules/jquery/src/data/var/acceptData.js @@ -0,0 +1,18 @@ +define( function() { + +/** + * Determines whether an object can have data + */ +return function( owner ) { + + // Accepts only: + // - Node + // - Node.ELEMENT_NODE + // - Node.DOCUMENT_NODE + // - Object + // - Any + /* jshint -W018 */ + return owner.nodeType === 1 || owner.nodeType === 9 || !( +owner.nodeType ); +}; + +} ); |