Skip to content

Commit 44af6dc

Browse files
committed
Fix Lints
1 parent 6700661 commit 44af6dc

File tree

1 file changed

+11
-12
lines changed

1 file changed

+11
-12
lines changed

hook.php

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -443,17 +443,16 @@ function plugin_formcreator_hook_add_ticket(CommonDBTM $item) {
443443
]);
444444
}
445445

446-
function plugin_formcreator_hook_update_ticket_actors(CommonITILActor $item)
447-
{
448-
if ($item::$itemtype_1 == Ticket::class) {
449-
if ($item->fields['type'] == CommonITILActor::REQUESTER) {
450-
$ticket_id = $item->fields['tickets_id'];
451-
$ticket = new Ticket();
452-
if ($ticket->getFromDB($ticket_id)) {
453-
plugin_formcreator_hook_update_ticket($ticket);
454-
}
455-
}
456-
}
446+
function plugin_formcreator_hook_update_ticket_actors(CommonITILActor $item) {
447+
if ($item::$itemtype_1 == Ticket::class) {
448+
if ($item->fields['type'] == CommonITILActor::REQUESTER) {
449+
$ticket_id = $item->fields['tickets_id'];
450+
$ticket = new Ticket();
451+
if ($ticket->getFromDB($ticket_id)) {
452+
plugin_formcreator_hook_update_ticket($ticket);
453+
}
454+
}
455+
}
457456
}
458457

459458
function plugin_formcreator_hook_update_ticket(CommonDBTM $item) {
@@ -503,7 +502,7 @@ function plugin_formcreator_hook_update_ticket(CommonDBTM $item) {
503502
'entities_id' => $item->fields['entities_id'],
504503
'is_recursive' => '0',
505504
'requester_id' => $requester,
506-
'users_id_recipient' => $item->fields['users_id_recipient'],
505+
'users_id_recipient' => $requester,
507506
'comment' => $DB->escape($item->fields['content']),
508507
]);
509508
}

0 commit comments

Comments
 (0)