fix(ns): root-qualify PHP builtins after PSR-4 move

Namespaced classes resolved DateTimeImmutable etc. under AKSRT\*
(e.g. Credits\DateTimeImmutable). Prefix with \ globally.
This commit is contained in:
kate522 committed 2026-07-17 15:05:03 +08:00
1 parent 0335517467
commit da59d550ad
7 files changed
+15 -15

No files matched your search

+1 -1
View File
@@ -57,7 +57,7 @@ class Earn {
if ($user_id <= 0 || !class_exists('PointsFree')) {
return;
}
$today = (new DateTimeImmutable('today', wp_timezone()))->format('Y-m-d');
$today = (new \DateTimeImmutable('today', wp_timezone()))->format('Y-m-d');
$last = (string) get_user_meta($user_id, PointsFree::META_LOGIN, true);
if ($last === $today) {
return;