Skip to content

Commit fd6b80c

Browse files
author
Lauren McCarthy
committed
1 parent a25831c commit fd6b80c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/core.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ var p5 = function(sketch, node, sync) {
231231
this._preloadMethods[method] = this._preloadMethods[method] || p5;
232232
var obj = this._preloadMethods[method];
233233
//it's p5, check if it's global or instance
234-
if (obj === p5.prototype){
234+
if (obj === p5.prototype || obj === p5){
235235
obj = this._isGlobal ? window : this;
236236
}
237237
this._registeredPreloadMethods[method] = obj[method];

0 commit comments

Comments
 (0)