diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index c71ba0bfc96..94f4d238ee3 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -13,7 +13,7 @@ * Copyright (C) 2014 Cédric GROSS * Copyright (C) 2014-2015 Marcos García * Copyright (C) 2015 Jean-François Ferry - * Copyright (C) 2018-2020 Frédéric France + * Copyright (C) 2018-2021 Frédéric France * Copyright (C) 2019 Thibault Foucart * Copyright (C) 2020 Open-Dsi * Copyright (C) 2021 Gauthier VERDOL @@ -2480,12 +2480,14 @@ function dol_print_socialnetworks($value, $cid, $socid, $type, $dictsocialnetwor $htmllink = $value; - if (empty($value)) return ' '; + if (empty($value)) { + return ' '; + } if (!empty($type)) { $htmllink = '
'; - // TODO use dictionary definition for picto $dictsocialnetworks[$type]['icon'] - $htmllink .= img_picto($langs->trans(dol_ucfirst($type)), $type.'.png', '', false, 0, 0, '', 'paddingright', 0); + // Use dictionary definition for picto $dictsocialnetworks[$type]['icon'] + $htmllink .= ''; if ($type == 'skype') { $htmllink .= $value; $htmllink .= ' '; @@ -2501,7 +2503,9 @@ function dol_print_socialnetworks($value, $cid, $socid, $type, $dictsocialnetwor if (($cid || $socid) && !empty($conf->agenda->enabled) && $user->rights->agenda->myactions->create) { $addlink = 'AC_SKYPE'; $link = ''; - if (!empty($conf->global->AGENDA_ADDACTIONFORSKYPE)) $link = ''.img_object($langs->trans("AddAction"), "calendar").''; + if (!empty($conf->global->AGENDA_ADDACTIONFORSKYPE)) { + $link = ''.img_object($langs->trans("AddAction"), "calendar").''; + } $htmllink .= ($link ? ' '.$link : ''); } } else {