more version

This commit is contained in:
Shish
2019-11-03 19:49:52 +00:00
parent 539dd66fe8
commit f15a95b4de
17 changed files with 58 additions and 70 deletions

View File

@ -7,7 +7,7 @@ class Notes extends Extension
global $config, $database;
// shortcut to latest
if ($config->get_int("ext_notes_version") < 1) {
if ($this->get_version("ext_notes_version") < 1) {
$database->Execute("ALTER TABLE images ADD COLUMN notes INTEGER NOT NULL DEFAULT 0");
$database->create_table("notes", "
id SCORE_AIPK,
@ -59,8 +59,7 @@ class Notes extends Extension
$config->set_int("notesRequestsPerPage", 20);
$config->set_int("notesHistoriesPerPage", 20);
$config->set_int("ext_notes_version", 1);
log_info("notes", "extension installed");
$this->set_version("ext_notes_version", 1);
}
}