Skip to content

Commit 15c0bf6

Browse files
committed
PES-2886: Reformat conditional for readability in packetery.php
1 parent 0660574 commit 15c0bf6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packetery/packetery.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1033,7 +1033,10 @@ public function packeteryHookDisplayAdminOrder($params)
10331033
$this->context->smarty->assign('postParcelButtonAllowed', $postParcelButtonAllowed && $canUserEditOrders);
10341034
$this->context->smarty->assign('showActionButtonsDivider', $showActionButtonsDivider && $canUserEditOrders);
10351035

1036-
if ($this->diContainer->get(\Packetery\Log\LogRepository::class)->hasAnyByOrderId($orderId) && $userPermissionHelper->hasPermission(\Packetery\Tools\UserPermissionHelper::SECTION_LOG, \Packetery\Tools\UserPermissionHelper::PERMISSION_VIEW)) {
1036+
if (
1037+
$this->diContainer->get(\Packetery\Log\LogRepository::class)->hasAnyByOrderId($orderId)
1038+
&& $userPermissionHelper->hasPermission(\Packetery\Tools\UserPermissionHelper::SECTION_LOG, \Packetery\Tools\UserPermissionHelper::PERMISSION_VIEW)
1039+
) {
10371040
$this->context->smarty->assign('logLink', $this->getAdminLink('PacketeryLogGrid', ['id_order' => $orderId]));
10381041
}
10391042

0 commit comments

Comments
 (0)