@@ -293,6 +293,7 @@ public function add_rule($language = 0, $parent_id = 0)
293293 add_form_key ('add_edit_rule ' );
294294
295295 // Initiate a rule entity
296+ /* @var $entity \phpbb\boardrules\entity\rule */
296297 $ entity = $ this ->container ->get ('phpbb.boardrules.entity ' );
297298
298299 // Collect the form data
@@ -459,7 +460,7 @@ protected function add_edit_rule_data($entity, $data)
459460 }
460461 catch (\phpbb \boardrules \exception \out_of_bounds $ e )
461462 {
462- trigger_error ($ e ->get_message ($ this ->user ) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
463+ trigger_error ($ e ->get_message ($ this ->lang ) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
463464 }
464465
465466 // Change rule parent
@@ -471,7 +472,7 @@ protected function add_edit_rule_data($entity, $data)
471472 }
472473 catch (\Exception $ e )
473474 {
474- trigger_error ($ this ->user ->lang ($ e ->getMessage ()) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
475+ trigger_error ($ this ->lang ->lang ($ e ->getMessage ()) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
475476 }
476477 }
477478
@@ -487,7 +488,7 @@ protected function add_edit_rule_data($entity, $data)
487488 }
488489 catch (\phpbb \boardrules \exception \out_of_bounds $ e )
489490 {
490- trigger_error ($ e ->get_message ($ this ->user ) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
491+ trigger_error ($ e ->get_message ($ this ->lang ) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
491492 }
492493
493494 // Show user confirmation of the added rule and provide link back to the previous page
@@ -555,7 +556,7 @@ public function delete_rule($rule_id)
555556 }
556557 catch (\Exception $ e )
557558 {
558- trigger_error ($ this ->user ->lang ($ e ->getMessage ()) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
559+ trigger_error ($ this ->lang ->lang ($ e ->getMessage ()) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
559560 }
560561
561562 // Show user confirmation of the deleted rule and provide link back to the previous page
@@ -600,7 +601,7 @@ public function move_rule($rule_id, $direction, $amount = 1)
600601 }
601602 catch (\Exception $ e )
602603 {
603- trigger_error ($ this ->user ->lang ($ e ->getMessage ()) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
604+ trigger_error ($ this ->lang ->lang ($ e ->getMessage ()) . adm_back_link ($ this ->u_action ), E_USER_WARNING );
604605 }
605606
606607 // Send a JSON response if an AJAX request was used
0 commit comments