Fixed logic error in getReasonableScale.