fixes null problem