changed Node API, made consequent changes