Refactored. Added server.