Exemplo n.º 1
0
 /**
  * Check validation and hashing password
  * @param array $data
  * @return boolean|array errors
  */
 protected function _modify(array $data = null)
 {
     if ($this->is_valid()) {
         if (isset($data['password'])) {
             $this->password = Auth::hash($data['password']);
         }
         return $this->save();
     }
     return $this->errors->full_messages();
 }