MCPcopy Create free account
hub / github.com/TruthHun/BookStack / isArrayLike

Function isArrayLike

static/webuploader/webuploader.js:1224–1239  ·  view source on GitHub ↗
( obj )

Source from the content-addressed store, hash-verified

1222 widgetClass = [];
1223
1224 function isArrayLike( obj ) {
1225 if ( !obj ) {
1226 return false;
1227 }
1228
1229 var length = obj.length,
1230 type = $.type( obj );
1231
1232 if ( obj.nodeType === 1 && length ) {
1233 return true;
1234 }
1235
1236 return type === 'array' || type !== 'function' && type !== 'string' &&
1237 (length === 0 || typeof length === 'number' && length > 0 &&
1238 (length - 1) in obj);
1239 }
1240
1241 function Widget( uploader ) {
1242 this.owner = uploader;

Callers 1

webuploader.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected