forked from Cavemanon/cavepaintings
requestcontext stuff is messy, go back to globals :(
This commit is contained in:
@ -3,13 +3,12 @@
|
||||
class Upgrade implements Extension {
|
||||
public function receive_event(Event $event) {
|
||||
if($event instanceof InitExtEvent) {
|
||||
$this->do_things($event->context);
|
||||
$this->do_things();
|
||||
}
|
||||
}
|
||||
|
||||
private function do_things($context) {
|
||||
$config = $context->config;
|
||||
$database = $context->database;
|
||||
private function do_things() {
|
||||
global $config, $database;
|
||||
|
||||
if(!is_numeric($config->get_string("db_version"))) {
|
||||
$config->set_int("db_version", 2);
|
||||
|
Reference in New Issue
Block a user