refactoring webrick