fixed primEq so it works