Fixed bug in argument decorator

Decorator failed to forward prototypes of the inner
function to the returned one, therefore if a class
constructor attempted to use this all of its
prototype members and functions would be lost.