Author Topic: Superuser Flags  (Read 4101 times)

A Cool Guy

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
    • Code Angels Game
Superuser Flags
« on: July 31, 2010, 09:33:55 pm »
When i tick

See PHP Notices in debug output

i get this error everywhere

PHP Notice: "Undefined variable: setDefault"
in /home/gothicga/public_html/lib/settings.class.php at 75.
PHP Notice: "Undefined variable: setDefault"
in /home/gothicga/public_html/lib/settings.class.php at 76.

dont know if its a bug or coding error or server error so any ideas would help pleas thanks.
If i can i will.
If i cant i wont :)

Nightborn

  • Administrator
  • Sr. Member
  • *****
  • Posts: 320
  • Karma: +20/-0
    • View Profile
    • Shinobilegends
Re: Superuser Flags
« Reply #1 on: August 11, 2010, 05:38:16 am »
Post the URL pls =) or name the site
It should be fixed, but it won't be easy and it won't be fast. If you want
to help - wonderful. But keep in mind that it will take months of wading
through the ugliest code we have in the tree. If you've got a weak stomach -
stay out. I've been there and it's not a nice place.

   - Al Viro

A Cool Guy

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
    • Code Angels Game
Re: Superuser Flags
« Reply #2 on: August 11, 2010, 09:04:48 am »
If i can i will.
If i cant i wont :)

Nightborn

  • Administrator
  • Sr. Member
  • *****
  • Posts: 320
  • Karma: +20/-0
    • View Profile
    • Shinobilegends
Re: Superuser Flags
« Reply #3 on: September 17, 2010, 08:07:32 pm »
Sorry for the late reply.

lib/settings.class.php
 69                 if (!isset($this->settings[$settingname])){
 70                         //nothing set, we have to use the default value
 71                         if (file_exists("lib/data/".$this->tablename.".php")) require("lib/data/".$this->tablename.".php");
 72                         if ($default===false) {
 73                                 if (isset($defaults[$settingname])) $setDefault=$defaults[$settingname];
 74                                         else $setDefault='';
 75                         } else $setDefault=$default;


Add that - will be in the 1.2.3 then. It's just you have a module that does not set a default value for a variable, hence the error. It's an old core "bug" so to speak.
It should be fixed, but it won't be easy and it won't be fast. If you want
to help - wonderful. But keep in mind that it will take months of wading
through the ugliest code we have in the tree. If you've got a weak stomach -
stay out. I've been there and it's not a nice place.

   - Al Viro

A Cool Guy

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
    • Code Angels Game
Re: Superuser Flags
« Reply #4 on: September 17, 2010, 10:22:45 pm »
Brilliant thanks :)
If i can i will.
If i cant i wont :)