Fixed Devision by zero error