Skip to content

Commit

Permalink
TASK: Solve code style issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebobo committed Dec 20, 2024
1 parent 36e6daf commit 775713c
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Neos.Workspace.Ui/Classes/Controller/WorkspaceController.php
Original file line number Diff line number Diff line change
Expand Up @@ -706,9 +706,13 @@ protected function computePendingChanges(Workspace $selectedWorkspace, ContentRe
{
$changesCount = ['new' => 0, 'changed' => 0, 'removed' => 0];
foreach($this->getChangesFromWorkspace($selectedWorkspace, $contentRepository) as $change) {
if($change->deleted) $changesCount['removed']++;
elseif($change->created) $changesCount['new']++;
else $changesCount['changed']++;
if ($change->deleted) {
$changesCount['removed']++;
} elseif ($change->created) {
$changesCount['new']++;
} else {
$changesCount['changed']++;
}
}
return new PendingChanges(new: $changesCount['new'], changed: $changesCount['changed'], removed:$changesCount['removed']);
}
Expand Down

0 comments on commit 775713c

Please sign in to comment.