Refactor node server stuff.