Fix error  undefined method `>' for nil:NilClass

Because I had added a debug line I was looking first at the wrong line!