support falsy and null super classes - fixes #284
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
(function (child, parent) {
|
||||
child.prototype = Object.create(parent.prototype, {
|
||||
child.prototype = Object.create(parent && parent.prototype, {
|
||||
constructor: {
|
||||
value: child,
|
||||
enumerable: false,
|
||||
@@ -7,5 +7,5 @@
|
||||
configurable: true
|
||||
}
|
||||
});
|
||||
child.__proto__ = parent;
|
||||
if (parent) child.__proto__ = parent;
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user