fixed stupid null pointer :/