fixed bug that was crashing the update