Replaced Catalog model's nasty if by nice regex