Fix dumb mistake in the comparison function