mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-19 14:10:14 -05:00
Prevent overriding exported classes by inheriting classes with same _class value.
This commit is contained in:
parent
d8188e8ddc
commit
75c1225d4f
1 changed files with 1 additions and 1 deletions
|
@ -88,7 +88,7 @@ Base.inject(/** @lends Base# */{
|
|||
// for deserialization and injection into PaperScope.
|
||||
var res = extend.base.apply(this, arguments),
|
||||
name = res.prototype._class;
|
||||
if (name)
|
||||
if (name && !Base.exports[name])
|
||||
Base.exports[name] = res;
|
||||
return res;
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue