Avoid instanceof due to Node Webkit dual contexts

Third time lucky? #417
Pretty sure its complaining about no space there

I'm -1 for this anyway as its a major perf regression