6.0.0-git
2019-03-19

[#6040] mnemo renders php error if $GLOBALS['display_notepads'] is not defined
Summary mnemo renders php error if $GLOBALS['display_notepads'] is not defined
Queue Mnemo
Queue Version 2.2-RC1
Type Bug
State Not A Bug
Priority 1. Low
Owners
Requester m.gabriel (at) das-netzwerkteam (dot) de
Created 2007-12-24 (4103 days ago)
Due
Updated 2007-12-26 (4101 days ago)
Assigned 2007-12-25 (4102 days ago)
Resolved 2007-12-26 (4101 days ago)
Milestone
Patch No

History
2007-12-26 04:18:38 Chuck Hagenbuch State ⇒ Not A Bug
 
2007-12-25 11:52:04 m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #3 Reply to this comment
ohhh... you are right. there was an error in my mnemo config dir. by 
some reason mnemo had a kronolith prefs.php file.



i guess, then this can be considered as a "rejected ticket".



greets,

mike
2007-12-25 03:46:54 Chuck Hagenbuch Taken from Horde DevelopersHorde Developers
 
2007-12-25 03:46:44 Chuck Hagenbuch Comment #2
Assigned to Horde DevelopersHorde Developers
State ⇒ Feedback
Reply to this comment
$GLOBALS['display_notepads'] would only not be an array if the 
display_notepads preference was corrupted, or if you didn't have an up 
to date prefs.php config file. Do you know what the cause was in your 
case?
2007-12-24 23:45:54 m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #1
Type ⇒ Bug
State ⇒ Unconfirmed
Priority ⇒ 1. Low
Summary ⇒ mnemo renders php error if $GLOBALS['display_notepads'] is not defined
Queue ⇒ Mnemo
Reply to this comment
i am using kolab-2.1 (debian unstable) and horde-webmail-1.1rc1



the patch below silenced this php5 error if 
$GLOBALS['display_notepads'] is undefined...



Warning: Invalid argument supplied for foreach() in 
/usr/local/share/_horde-versions_/horde-webmail-1.1-rc1-netzwerkteam/mnemo/lib/Mnemo.php on line 
403



diff -r horde-webmail-1.1-rc1/mnemo/lib/Mnemo.php 
horde-webmail-1.1-rc1-netzwerkteam/mnemo/lib/Mnemo.php

402,406c402,408

<         foreach ($_temp as $id) {

<             if (isset($_all[$id])) {

<                 $GLOBALS['display_notepads'][] = $id;

<             }

<         }

---
       if ($_temp) {
           foreach ($_temp as $id) {
                 if (isset($_all[$id])) {
                   $GLOBALS['display_notepads'][] = $id;
               }
           }
       }
mike

Saved Queries