diff --git a/src/babel/transformation/templates/helper-create-decorated-class.js b/src/babel/transformation/templates/helper-create-decorated-class.js index cab51157e0..8c36074cdb 100644 --- a/src/babel/transformation/templates/helper-create-decorated-class.js +++ b/src/babel/transformation/templates/helper-create-decorated-class.js @@ -23,7 +23,7 @@ throw new TypeError("The decorator for method " + descriptor.key + " is of the invalid type " + typeof decorator); } } - initializers[key] = descriptor.initializer; + if (initializers) initializers[key] = descriptor.initializer; } Object.defineProperty(target, key, descriptor);