Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

populateTypes() throws error with Node 0.9.4 #2

Closed
airandfingers opened this issue Feb 21, 2013 · 1 comment
Closed

populateTypes() throws error with Node 0.9.4 #2

airandfingers opened this issue Feb 21, 2013 · 1 comment
Assignees
Labels

Comments

@airandfingers
Copy link

My app calls $.populateTypes, and it works fine with Node 0.8.16, but with Node 0.9.4 I get the following error:

/path/to/node_modules/node-class/index.js:29
        Array.append = sugar.ArrayAppend;
                     ^
TypeError: Cannot assign to read only property 'append' of function Array() { [native code] }
    at Object.module.exports.populateTypes (/path/to/node_modules/node-class/index.js:29:22)

I've worked around the issue by replacing my calls to Object.merge with $.ObjectMerge, but definitely prefer the syntactic sugar.

By the way, thanks for making this awesome module!

@ghost ghost assigned llafuente Mar 22, 2013
@llafuente
Copy link
Owner

Sorry for the delay I didnt recieve any email so i didnt get noticed

About the issue. There is no workaround, V8 seems to define that function as read-only so rename is the only solution. I can't find what/why/when this was included...
so:
append -> Append

Thanks and have fun with the module!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants