Skip to content

Commit

Permalink
Fixed instanceof not working with classes.
Browse files Browse the repository at this point in the history
  • Loading branch information
TobiaszCudnik committed Mar 11, 2012
1 parent 19af5fc commit 936a20c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/contracts.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -621,7 +621,8 @@ object = (objContract, options = {}, name) ->
new bf()
)
else
op = Proxy.create(handler, Object::)
proto = obj?.constructor?.prototype or Object::
op = Proxy.create(handler, proto)
unproxy.set op, this
op
)
Expand Down

0 comments on commit 936a20c

Please sign in to comment.