Because I know you will extend the check later on, this will do, but next time simply store a pattern and extend the Regexp class.