Check string with regex