Code refactoring so that server reflects local host code