Closed toha closed 13 years ago
I declared a function on the client
now.foo = function() { console.log("foo"); };
and I can use it on the server with
user.now.foo();
But, if i redeclare the function in the client
now.foo = function() { console.log("bar"); };
I cannot access it from the server anymore:
TypeError: Property 'foo' of object # is not a function.
On first declaration, nowjs sends: 5:::{"name":"rv","args":[{"now.foo":{"fqn":"now.foo"}}]}
and on the second declaration: 5:::{"name":"rv","args":[{"now.foo.fqn":"now.foo"}]}
Reproduced. Fixing...
Hi toha, this issue has been fixed in the latest GH master.
Eric
Additionally I've updated our test suite to ensure this does not go uncaught again.
I declared a function on the client
now.foo = function() { console.log("foo"); };
and I can use it on the server with
user.now.foo();
But, if i redeclare the function in the client
now.foo = function() { console.log("bar"); };
I cannot access it from the server anymore:
TypeError: Property 'foo' of object #
On first declaration, nowjs sends: 5:::{"name":"rv","args":[{"now.foo":{"fqn":"now.foo"}}]}
and on the second declaration: 5:::{"name":"rv","args":[{"now.foo.fqn":"now.foo"}]}