Fixes problem with comparing fraction to infinity.

Comparing a fraction to infinity causes an error "Can't convert Fraction to an Infinity".  This fixes that problem.