Fix lastInsertIds

This commit is contained in:
patrick 2025-02-07 03:52:52 +00:00
parent f12445c5d0
commit a31417285d

View File

@ -176,7 +176,7 @@ case 'email_save':
$q = $pdo->prepare("INSERT INTO emails(type,val) VALUES('$type','$key')");
$q->execute();
show_pdo_errors_if_any($pdo);
$id = lastInsertId();
$id = $pdo->lastInsertId();
} else {
error_('Email Key and Name are required');
exit;
@ -885,7 +885,7 @@ if (get_value_from_array($_GET, 'action') == 'send' && get_value_from_array($_GE
$numtotal,
0)");
$q->execute();
$emailqueueid = lastInsertId();
$emailqueueid = $pdo->lastInsertId();
show_pdo_errors_if_any($pdo);
$urlproto = $_SERVER['SERVER_PORT'] == 443 ? 'https://' : 'http://';