
Originally Posted by
carlwhat
@mc12345678 you are wrong.
the keys method is not the place to install configuration values. if one were to add the global $db declaration in said method, what happens when we call the install method, and we try to execute lines 127 and 128? we would now have an attempt to insert a duplicate key into the configuration table. (i can't remember which method gets called first, the result is the same.)
i would encourage you to test your recommendations (as i did) prior to making them. adding the global $db declaration just causes a new error. and, to me, it's pretty clear where the config values should get installed.... in the install method.
this is the answer and the best help for the OPs issue.