/**
  * Sets an array of errors
  *
  * If an existing error name matches any of the keys in the supplied
  * array, the associated message will be overridden.
  *
  * @param  sfRequest $request A request object
  * @param array $erros An associative array of errors and their associated messages
  *
  */
 public static function setErrors($request, $errors)
 {
     $request->setAttribute('errors', array_merge($request->getAttribute('errors', array()), $errors));
 }