Few bugfixes - about to convert server to C#

Will retain compatibility with node.js for the next few commits?