Throw specific exception caused by invalid email regex in config

Users will see invalid pattern error instead of internal server error.
At present, attempting to push when the project config has an illegible
email pattern restriction such as a single asterisk results in an
internal server error and failed commit. With this change, the response
provides greater clarity.

This is not the solution to allowing illegible email patterns to be set,
but it clarifies what is preventing the commit from going through.

Change-Id: I66447139a3611b81c5c8805c263015702d9f2f5b
(cherry picked from commit 963c161389ec20862920e05658e36c0acb68ec71)
2 files changed