Merge from kota ghost user fix

https://github.com/Zarel/Pokemon-Showdown/pull/522
https://github.com/kotarou3