Fixed a critical bug that would crash the whole server.

http://i.imgur.com/rimGwvW.png :(