1
1
Fork 0

Fix 2FA AppSpecificPassword

This commit is contained in:
Philipp Holzer 2021-12-12 20:09:10 +01:00
parent 474c185294
commit 5f3421701f
Signed by: nupplaPhil
GPG key ID: 24A7501396EB5432

View file

@ -86,9 +86,11 @@ class AppSpecificPassword
$appSpecificPasswords = DBA::toArray($appSpecificPasswordsStmt); $appSpecificPasswords = DBA::toArray($appSpecificPasswordsStmt);
array_walk($appSpecificPasswords, function (&$value) { array_walk($appSpecificPasswords, function (&$value) {
$value['ago'] = Temporal::getRelativeDate($value['last_used']); $last_used = $value['last_used'] ?? DBA::NULL_DATETIME;
$value['utc'] = DateTimeFormat::utc($value['last_used'], 'c');
$value['local'] = DateTimeFormat::local($value['last_used'], 'r'); $value['ago'] = Temporal::getRelativeDate($last_used);
$value['utc'] = DateTimeFormat::utc($last_used, 'c');
$value['local'] = DateTimeFormat::local($last_used, 'r');
}); });
return $appSpecificPasswords; return $appSpecificPasswords;