organizing code into express framework