Fixed a bug in server-side