Fix no such method issue for getOnlinePlayers.