Fixed usage of enum where the enum's value should be used

This commit is contained in:
Alejandro Celaya 2022-09-30 17:26:22 +02:00
parent 1daad334a5
commit d3faa22b78

View File

@ -148,7 +148,7 @@ class ApiKey extends AbstractEntity
if ($this->hasRole($role)) {
/** @var ApiKeyRole $apiKeyRole */
$apiKeyRole = $this->roles->get($role);
$apiKeyRole = $this->roles->get($role->value);
$apiKeyRole->updateMeta($meta);
} else {
$apiKeyRole = new ApiKeyRole($roleDefinition->role, $roleDefinition->meta, $this);