fix mode compare