Refactor datetime_convert() into Temporal::convert()
This commit is contained in:
@@ -5,10 +5,12 @@
|
||||
* Version: 1.0
|
||||
* Author: Mike Macgirvin <http://macgirvin.com/profile/mike>
|
||||
*/
|
||||
|
||||
use Friendica\Core\Addon;
|
||||
use Friendica\Core\Config;
|
||||
use Friendica\Core\L10n;
|
||||
use Friendica\Model\User;
|
||||
use Friendica\Util\Temporal;
|
||||
|
||||
function testdrive_install() {
|
||||
|
||||
@@ -42,7 +44,7 @@ function testdrive_register_account($a,$b) {
|
||||
return;
|
||||
|
||||
$r = q("UPDATE user set account_expires_on = '%s' where uid = %d",
|
||||
dbesc(datetime_convert('UTC','UTC','now +' . $days . ' days')),
|
||||
dbesc(Temporal::convert('now +' . $days . ' days')),
|
||||
intval($uid)
|
||||
);
|
||||
|
||||
@@ -70,7 +72,7 @@ function testdrive_cron($a,$b) {
|
||||
]);
|
||||
|
||||
q("update user set expire_notification_sent = '%s' where uid = %d",
|
||||
dbesc(datetime_convert()),
|
||||
dbesc(Temporal::convert()),
|
||||
intval($rr['uid'])
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user