1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-22 06:42:42 +01:00

Fix undefined variable in HeraldAction

Summary: `$no_permission` is only defined within `if ($object instanceof PhabricatorPolicyInterface)`, thus move the check for `if ($no_permission)` into that clause.

Test Plan: Read the code.

Reviewers: O1 Blessed Committers, valerio.bozzolan

Reviewed By: O1 Blessed Committers, valerio.bozzolan

Subscribers: tobiaswiese, valerio.bozzolan, Matthew, Cigaryno

Differential Revision: https://we.phorge.it/D25741
This commit is contained in:
Andre Klapper 2024-07-24 17:47:46 +02:00
parent a039c4952f
commit 0b93685cc9

View file

@ -298,11 +298,10 @@ abstract class HeraldAction extends Phobject {
$no_permission[] = $phid;
unset($targets[$phid]);
}
}
if ($no_permission) {
$this->logEffect(self::DO_STANDARD_PERMISSION, $no_permission);
}
}
return $targets;
}