Remove unused upubkey and uprvkey from queries
- Switched queries to new dba::* functions
This commit is contained in:
parent
ec6f5193e2
commit
2196a0577b
8 changed files with 49 additions and 43 deletions
|
@ -33,7 +33,8 @@ function openid_content(App $a) {
|
|||
// mod/settings.php in 8367cad so it might have left mixed
|
||||
// records in the user table
|
||||
//
|
||||
$r = q("SELECT *, `user`.`pubkey` as `upubkey`, `user`.`prvkey` as `uprvkey` FROM `user`
|
||||
$r = q("SELECT *
|
||||
FROM `user`
|
||||
WHERE ( `openid` = '%s' OR `openid` = '%s' )
|
||||
AND `blocked` = 0 AND `account_expired` = 0
|
||||
AND `account_removed` = 0 AND `verified` = 1
|
||||
|
|
|
@ -506,14 +506,14 @@ function settings_post(App $a) {
|
|||
}
|
||||
// check the email is valid
|
||||
if (!valid_email($email)) {
|
||||
$err .= t(' Not valid email.');
|
||||
$err .= t('Invalid email.');
|
||||
}
|
||||
// ensure new email is not the admin mail
|
||||
//if ((x($a->config, 'admin_email')) && (strcasecmp($email, $a->config['admin_email']) == 0)) {
|
||||
if (x($a->config, 'admin_email')) {
|
||||
$adminlist = explode(",", str_replace(" ", "", strtolower($a->config['admin_email'])));
|
||||
if (in_array(strtolower($email), $adminlist)) {
|
||||
$err .= t(' Cannot change to that email.');
|
||||
$err .= t('Cannot change to that email.');
|
||||
$email = $a->user['email'];
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue