Fixed server side bugs