update using nan and v0.11 support added