Skip to content

Instantly share code, notes, and snippets.

@jesalg jesalg/gist:4689966
Last active Dec 12, 2015

Embed
What would you like to do?
class User extends AppModel {
public function beforeSave($options = array()) {
if (isset($this->data['User']['password'])) {
$this->data['User']['password'] = AuthComponent::password($this->data['User']['password'], $this->data['User']['email']);
}
return true;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.