Fixed error messages for primes