Bug fix for a problem that only occurs on server