Better error codes

Make the regexp case insensitive (once again @merlinND idea ;))