Rob code refactor, sinatra tests passing, not returning any 500s