compatibility fix for node 0.10+