forked from Wavyzz/dolibarr
Qual: Fix phan notices (main.inc,master.inc)
This commit is contained in:
@@ -12,12 +12,12 @@
|
||||
* Copyright (C) 2014-2015 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
|
||||
* Copyright (C) 2020 Demarest Maxime <maxime@indelog.fr>
|
||||
* Copyright (C) 2020-2024 Charlene Benke <charlene@patas-monkey.com>
|
||||
* Copyright (C) 2020-2024 Charlene Benke <charlene@patas-monkey.com>
|
||||
* Copyright (C) 2021-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2021 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2023 Joachim Küter <git-jk@bloxera.com>
|
||||
* Copyright (C) 2023 Eric Seigne <eric.seigne@cap-rel.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@@ -255,7 +255,7 @@ function testSqlAndScriptInject($val, $type)
|
||||
/**
|
||||
* Return true if security check on parameters are OK, false otherwise.
|
||||
*
|
||||
* @param string|array<string,string> $var Variable name
|
||||
* @param string|array<int|string,string> $var Variable name
|
||||
* @param int<0,2> $type 1=GET, 0=POST, 2=PHP_SELF
|
||||
* @param int<0,1> $stopcode 0=No stop code, 1=Stop code (default) if injection found
|
||||
* @return boolean True if there is no injection.
|
||||
@@ -3133,7 +3133,7 @@ function printDropdownQuickadd($mode = 0)
|
||||
// Allow the $items of the menu to be manipulated by modules
|
||||
$parameters = array();
|
||||
$hook_items = $items;
|
||||
$reshook = $hookmanager->executeHooks('menuDropdownQuickaddItems', $parameters, $hook_items); // Note that $action and $object may have been modified by some hooks
|
||||
$reshook = $hookmanager->executeHooks('menuDropdownQuickaddItems', $parameters, $hook_items); // Note that $action and $object may have been modified by some hooks @phan-suppress-current-line PhanTypeMismatchArgument
|
||||
if (is_numeric($reshook) && !empty($hookmanager->resArray) && is_array($hookmanager->resArray)) {
|
||||
if ($reshook == 0) {
|
||||
$items['items'] = array_merge($items['items'], $hookmanager->resArray); // add
|
||||
@@ -3498,7 +3498,7 @@ function left_menu($menu_array_before, $helppagename = '', $notused = '', $menu_
|
||||
|
||||
//$textsearch = $langs->trans("Search");
|
||||
$textsearch = '<span class="fa fa-search paddingright pictofixedwidth"></span>'.$langs->trans("Search");
|
||||
$searchform .= $form->selectArrayFilter('searchselectcombo', $arrayresult, $selected, 'accesskey="s"', 1, 0, (getDolGlobalString('MAIN_SEARCHBOX_CONTENT_LOADED_BEFORE_KEY') ? 0 : 1), 'vmenusearchselectcombo', 1, $textsearch, 1, $stringforfirstkey.' s');
|
||||
$searchform .= $form->selectArrayFilter('searchselectcombo', $arrayresult, (string) $selected, 'accesskey="s"', 1, 0, (getDolGlobalString('MAIN_SEARCHBOX_CONTENT_LOADED_BEFORE_KEY') ? 0 : 1), 'vmenusearchselectcombo', 1, $textsearch, 1, $stringforfirstkey.' s');
|
||||
} else {
|
||||
if (is_array($arrayresult)) {
|
||||
// @phan-suppress-next-line PhanEmptyForeach // array is really empty in else case.
|
||||
|
||||
Reference in New Issue
Block a user