class-ified the server