require_once('include/email.php');
require_once('include/enotify.php');
+require_once('include/text.php');
function lostpass_post(&$a) {
dbesc($loginame)
);
- if(! count($r)) {
+ if(! dbm::is_result($r)) {
notice( t('No valid account found.') . EOL);
goaway(z_root());
}
$r = q("SELECT * FROM `user` WHERE `pwdreset` = '%s' LIMIT 1",
dbesc($hash)
);
- if(! count($r)) {
+ if(! dbm::is_result($r)) {
$o = t("Request could not be verified. \x28You may have previously submitted it.\x29 Password reset failed.");
return $o;
}