Closed Wilfred closed 6 years ago
Object.create(foo) produces an object that inherits properties from foo. This isn't necessarily harmful, but it can cause surprising behaviour:
Object.create(foo)
foo
> console.log(msg.message.user) { reply_to: 'test_room@conf.btf.hipchat.com', room: 'test_room' } > typeof msg.message.user "object" > console.log(msg.message.user.name) // should be undefined, surely? "Wilfred Hughes"
I think this is a worthwhile change as it makes debugging plugins easier.
Object.create(foo)
produces an object that inherits properties fromfoo
. This isn't necessarily harmful, but it can cause surprising behaviour:I think this is a worthwhile change as it makes debugging plugins easier.