Skip to content

Commit

Permalink
Added explanations
Browse files Browse the repository at this point in the history
  • Loading branch information
aschempp committed Dec 27, 2023
1 parent 5cc0ff6 commit afc89fb
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ public function __invoke(DataContainerOperation $operation): void
{
$data = StringUtil::deserialize($operation->getRecord()['data'] ?? null);
$table = $operation->getRecord()['fromTable'];

// We can only disable undo if the main record access is denied, because child records cannot
// check their permissions on a non-existing parent record. DC_Table::undo() will actually verify
// records again and skip the ones that are not allowed.
$row = $data[$table][0] ?? null;

if (
Expand Down

0 comments on commit afc89fb

Please sign in to comment.