Add audit log entry for lifted blacklist records
Some checks are pending
CI / release (push) Waiting to run
CI / debug (push) Waiting to run
CI / check-phpunit (push) Waiting to run
CI / check-phpdoc (push) Waiting to run
CI / generate-phpdoc (push) Blocked by required conditions
CI / test (push) Blocked by required conditions
CI / release-documentation (push) Blocked by required conditions
CI / release-artifacts (push) Blocked by required conditions
Some checks are pending
CI / release (push) Waiting to run
CI / debug (push) Waiting to run
CI / check-phpunit (push) Waiting to run
CI / check-phpdoc (push) Waiting to run
CI / generate-phpdoc (push) Blocked by required conditions
CI / test (push) Blocked by required conditions
CI / release-documentation (push) Blocked by required conditions
CI / release-artifacts (push) Blocked by required conditions
This commit is contained in:
parent
bda91ff955
commit
6861cbf708
2 changed files with 10 additions and 1 deletions
|
@ -20,5 +20,6 @@
|
||||||
case ENTITY_BLACKLISTED = 'ENTITY_BLACKLISTED';
|
case ENTITY_BLACKLISTED = 'ENTITY_BLACKLISTED';
|
||||||
case ENTITY_UNBLACKLISTED = 'ENTITY_UNBLACKLISTED';
|
case ENTITY_UNBLACKLISTED = 'ENTITY_UNBLACKLISTED';
|
||||||
|
|
||||||
case BLACKLIST_RECORD_DELETED = 'BLACKLIST_RECORD_DELETED';
|
case BLACKLIST_RECORD_DELETED = 'BLACKLIST_DELETED';
|
||||||
|
case BLACKLIST_LIFTED = 'BLACKLIST_LIFTED';
|
||||||
}
|
}
|
|
@ -3,6 +3,8 @@
|
||||||
namespace FederationServer\Methods\Blacklist;
|
namespace FederationServer\Methods\Blacklist;
|
||||||
|
|
||||||
use FederationServer\Classes\Configuration;
|
use FederationServer\Classes\Configuration;
|
||||||
|
use FederationServer\Classes\Enums\AuditLogType;
|
||||||
|
use FederationServer\Classes\Managers\AuditLogManager;
|
||||||
use FederationServer\Classes\Managers\BlacklistManager;
|
use FederationServer\Classes\Managers\BlacklistManager;
|
||||||
use FederationServer\Classes\RequestHandler;
|
use FederationServer\Classes\RequestHandler;
|
||||||
use FederationServer\Classes\Validate;
|
use FederationServer\Classes\Validate;
|
||||||
|
@ -49,6 +51,12 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
BlacklistManager::liftBlacklistRecord($blacklistUuid);
|
BlacklistManager::liftBlacklistRecord($blacklistUuid);
|
||||||
|
AuditLogManager::createEntry(AuditLogType::BLACKLIST_LIFTED, sprintf(
|
||||||
|
'Blacklist record %s lifted by %s (%s)',
|
||||||
|
$blacklistUuid,
|
||||||
|
$authenticatedOperator->getName(),
|
||||||
|
$authenticatedOperator->getUuid()
|
||||||
|
), $authenticatedOperator->getUuid(), $blacklistRecord->getEntity());
|
||||||
}
|
}
|
||||||
catch (DatabaseOperationException $e)
|
catch (DatabaseOperationException $e)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue