fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [17543]


From: nelson . guerra
Subject: [Fmsystem-commits] [17543]
Date: Wed, 10 Jan 2018 21:12:51 -0500 (EST)

Revision: 17543
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=17543
Author:   nelson224
Date:     2018-01-10 21:12:51 -0500 (Wed, 10 Jan 2018)
Log Message:
-----------


Modified Paths:
--------------
    branches/dev-syncromind/property/inc/class.soadmin.inc.php

Modified: branches/dev-syncromind/property/inc/class.soadmin.inc.php
===================================================================
--- branches/dev-syncromind/property/inc/class.soadmin.inc.php  2018-01-11 
02:12:35 UTC (rev 17542)
+++ branches/dev-syncromind/property/inc/class.soadmin.inc.php  2018-01-11 
02:12:51 UTC (rev 17543)
@@ -52,18 +52,21 @@
 
                function set_initials( $initials )
                {
-                       while (is_array($initials) && list($account_id, $value) 
= each($initials))
-                       {
-                               $this->db->query("UPDATE fm_ecouser set 
initials= '$value' WHERE id=$account_id ", __LINE__, __FILE__);
-                               if ($value)
-                               {
-                                       if (!$this->get_initials($account_id))
-                                       {
-                                               $account_lid = 
$GLOBALS['phpgw']->accounts->id2lid($account_id);
-                                               $this->db->query("INSERT INTO 
fm_ecouser (id,lid,initials) VALUES ($account_id,'$account_lid','$value' )", 
__LINE__, __FILE__);
-                                       }
-                               }
-                       }
+                        if (is_array($initials))
+                        {
+                            foreach($initials as $account_id => $value)
+                            {
+                                    $this->db->query("UPDATE fm_ecouser set 
initials= '$value' WHERE id=$account_id ", __LINE__, __FILE__);
+                                    if ($value)
+                                    {
+                                            if 
(!$this->get_initials($account_id))
+                                            {
+                                                    $account_lid = 
$GLOBALS['phpgw']->accounts->id2lid($account_id);
+                                                    $this->db->query("INSERT 
INTO fm_ecouser (id,lid,initials) VALUES ($account_id,'$account_lid','$value' 
)", __LINE__, __FILE__);
+                                            }
+                                    }
+                            }
+                        }
                }
 
                function read_fm_id()




reply via email to

[Prev in Thread] Current Thread [Next in Thread]