Example #1
0
 protected function before_update(&$data)
 {
     $data['salt'] = func::str_rand();
     $data['password'] = md5($data['password'] . $data['salt']);
 }