Removes warnings in profile edition.
authorStéphane Jacob <sj@m4x.org>
Wed, 8 Dec 2010 12:48:12 +0000 (13:48 +0100)
committerStéphane Jacob <sj@m4x.org>
Wed, 8 Dec 2010 12:50:05 +0000 (13:50 +0100)
Signed-off-by: Stéphane Jacob <sj@m4x.org>
modules/profile/jobs.inc.php
templates/profile/mentor.tpl

index bbd0951..e054404 100644 (file)
@@ -151,7 +151,7 @@ class ProfileSettingJob implements ProfileSetting
         if (count($job['terms'])) {
             $termsid = array();
             foreach ($job['terms'] as $term) {
-                if (!$term['full_name']) {
+                if (!isset($term['full_name'])) {
                     $termsid[] = $term['jtid'];
                 }
             }
@@ -162,7 +162,7 @@ class ProfileSettingJob implements ProfileSetting
                                  $termsid);
                 $term_id_to_name = $res->fetchAllAssoc('jtid', false);
                 foreach ($job['terms'] as &$term) {
-                    if (!$term['full_name']) {
+                    if (!isset($term['full_name'])) {
                         $term['full_name'] = $term_id_to_name[$term['jtid']];
                     }
                 }
index 56951e6..a24d2c1 100644 (file)
@@ -24,7 +24,7 @@
 
 <div>{icon name=information title="Afficher ma fiche référent"}Tu peux consulter ta <a class="popup2" href="referent/{$hrpid}">fiche référent</a> qui n'est accessible que par les X.
 </div>
-{if (!$expertise)||(!($sectors|@count))}
+{if !$expertise || !t($sectors) || !($sectors|@count)}
   <br /><div>
     <strong>{icon name=error title="Attention"} Attention&nbsp;: pour figurer dans la base de données des mentors, il faut remplir la
     dernière case en bas de cette page et avoir au moins un secteur d'activité de prédilection.</strong><br />