fixes for newer nodejs versions