save changes to smsemail
darcs-hash:20080721044604-84dde-c3e920bd56992c4e6a77625767b4599bacc74434.gz
This commit is contained in:
parent
13c1db0bce
commit
f538ab414b
@ -61,6 +61,8 @@ class ConfirmaddressAction extends Action {
|
||||
|
||||
if ($type == 'sms') {
|
||||
$cur->carrier = ($confirm->address_extra)+0;
|
||||
$carrier = Sms_carrier::staticGet($cur->carrier);
|
||||
$cur->smsemail = $carrier->toEmailAddress($cur->sms);
|
||||
}
|
||||
|
||||
$result = $cur->updateKeys($orig_user);
|
||||
|
@ -262,6 +262,7 @@ class SmssettingsAction extends EmailsettingsAction {
|
||||
$original = clone($user);
|
||||
$user->sms = NULL;
|
||||
$user->carrier = NULL;
|
||||
$user->smsemail = NULL;
|
||||
$result = $user->updateKeys($original);
|
||||
if (!$result) {
|
||||
common_log_db_error($user, 'UPDATE', __FILE__);
|
||||
|
@ -79,7 +79,7 @@ class User extends DB_DataObject
|
||||
|
||||
function updateKeys(&$orig) {
|
||||
$parts = array();
|
||||
foreach (array('nickname', 'email', 'jabber', 'sms', 'carrier') as $k) {
|
||||
foreach (array('nickname', 'email', 'jabber', 'sms', 'carrier', 'smsemail') as $k) {
|
||||
if (strcmp($this->$k, $orig->$k) != 0) {
|
||||
$parts[] = $k . ' = ' . $this->_quote($this->$k);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user