Avoiding divide by zero errors.