Browse Source

Merge pull request #27024 from nextcloud/enh/audit_log/expiration_date_removal

Properly log expiration date removal in audit log
pull/26936/head
Lukas Reschke 5 years ago
committed by GitHub
parent
commit
fd284f428d
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 29
      apps/admin_audit/lib/Actions/Sharing.php

29
apps/admin_audit/lib/Actions/Sharing.php

@ -320,15 +320,26 @@ class Sharing extends Action {
* @param array $params
*/
public function updateExpirationDate(array $params): void {
$this->log(
'The expiration date of the publicly shared %s with ID "%s" has been changed to "%s"',
$params,
[
'itemType',
'itemSource',
'date',
]
);
if ($params['date'] === null) {
$this->log(
'The expiration date of the publicly shared %s with ID "%s" has been changed removed',
$params,
[
'itemType',
'itemSource',
]
);
} else {
$this->log(
'The expiration date of the publicly shared %s with ID "%s" has been changed to "%s"',
$params,
[
'itemType',
'itemSource',
'date',
]
);
}
}
/**

Loading…
Cancel
Save