Fix for bad comparison of 2 numbers