fixed stupid error on integer comparision