<?xml version="1.0" encoding="UTF-8"?> 
<?xml-stylesheet href="https://dev.horde.org/themes/horde//default/feed-rss.xsl" type="text/xsl"?> 
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"> 
 <channel> 
  <title>ldap code overwrite last_login pref</title> 
  <pubDate>Fri, 10 Apr 2026 14:48:39 +0000</pubDate> 
  <link>https://bugs.horde.org/ticket/3390</link> 
  <atom:link rel="self" type="application/rss+xml" title="ldap code overwrite last_login pref" href="https://bugs.horde.org/ticket/3390/rss" /> 
  <description>ldap code overwrite last_login pref</description> 
 
   
   
  <item> 
   <title>I use ldap backend for preferences.

In horde+imp last_login</title> 
   <description>I use ldap backend for preferences.

In horde+imp last_login works.

In horde+imp+ingo last_login does not work anymore.



When imp loads preferences, it load horde preferences as well.

In that step it set last_login with the ldap value,

&quot;display&quot; last_login value

and set last_login to current time.



When ingo loads preferences, it load horde preferences as well.

In that step it set last_login with the ldap value and the 

last_login value from imp is lost.



If my workaround is usefull you can use it,

modify it, ...



------------------------------------------------------------

*** ldap.php.orig       Thu Feb  2 09:41:30 2006

--- ldap.php    Thu Feb  2 14:34:01 2006

***************

*** 382,389 ****



                  /* Retrieve this preference. */

                  if (isset($this-&gt;_prefs[$pref])) {

!                     $this-&gt;_setValue($pref, base64_decode($val), false);

!                     $this-&gt;setDefault($pref, false);

                  } else {

                      $this-&gt;add($pref, base64_decode($val), _PREF_SHARED);

                  }

--- 382,398 ----



                  /* Retrieve this preference. */

                  if (isset($this-&gt;_prefs[$pref])) {

!                     # when imp loads, the last_login is read from ldap

!                     # then imp set new value for last_login, but it does not write it to ldap yet

!                     # then ingo loads and last_login is read from ldap: last_login is overwriten with old value

!                     # so we need to check if last_login is globaly dirty and use global last_login value instead

!                     if ($GLOBALS[&#039;prefs&#039;]-&gt;isDirty($pref)) {

!                        $this-&gt;_setValue($pref, $GLOBALS[&#039;prefs&#039;]-&gt;getValue($pref), false);

!                        $this-&gt;setDefault($pref, false);

!                     } else {

!                        $this-&gt;_setValue($pref, base64_decode($val), false);

!                        $this-&gt;setDefault($pref, false);

!                     }

                  } else {

                      $this-&gt;add($pref, base64_decode($val), _PREF_SHARED);

                  }</description> 
   <pubDate>Thu, 02 Feb 2006 14:05:54 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/3390#t16162</link> 
  </item> 
   
  <item> 
   <title>I think this is actually a general flaw in the Prefs code, i</title> 
   <description>I think this is actually a general flaw in the Prefs code, in that it will load Horde preferences regardless of whether they&#039;re already loaded. This is a waste and also, as you diagnosed, can result in overwriting unwritten values.



I&#039;m still puzzling out the best fix; your way does work, but I think we&#039;ll arrive at something a bit different eventually. Needs to be fixed for at least the SQL driver as well, possibly more.</description> 
   <pubDate>Thu, 02 Feb 2006 19:55:32 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/3390#t16186</link> 
  </item> 
   
  <item> 
   <title>This is exacly the same bug I&#039;&#039;ve metioned in bug #2838 und </title> 
   <description>This is exacly the same bug I&#039;&#039;ve metioned in bug #2838 und #2829

Both marked as &quot;bogus&quot; !?!?!

Because some &quot;Horde-people&quot; (e.g. Michael Slusarz) are not able do find out differences between bufg #2838 und #2829 the second  bug is state bugus.



However bug #3390 is marked as bug with priority HIGH although a real simple bugfix (and the final solution for this problem) was provided in bug #2838  (163 days ago)!



Nevertheless this would be my last post on this stupid buf tracker list.



LecksMichAmOrsch</description> 
   <pubDate>Thu, 06 Apr 2006 20:42:36 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/3390#t18630</link> 
  </item> 
   
  <item> 
   <title>Duplicate of bug 2838.</title> 
   <description>Duplicate of bug 2838.</description> 
   <pubDate>Sun, 09 Apr 2006 00:11:33 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/3390#t18698</link> 
  </item> 
   
   
 
 </channel> 
</rss> 
