added comments to server code