fixing crashing