Skip to content

Commit

Permalink
increase migrations verion
Browse files Browse the repository at this point in the history
  • Loading branch information
marekfilip committed Sep 13, 2024
1 parent 6864ec7 commit 59b6655
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions data/web/inc/init_db.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ function init_db_schema() {
try {
global $pdo;

$db_version = "29072024_1000";
$db_version = "13082024_0927";

$stmt = $pdo->query("SHOW TABLES LIKE 'versions'");
$num_results = count($stmt->fetchAll(PDO::FETCH_ASSOC));
Expand Down Expand Up @@ -1005,7 +1005,7 @@ function init_db_schema() {
)
),
"attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
),
),
"pushover" => array(
"cols" => array(
"username" => "VARCHAR(255) NOT NULL",
Expand Down Expand Up @@ -1389,7 +1389,7 @@ function init_db_schema() {
"key_size" => 2048,
"max_quota_for_domain" => 10240 * 1048576,
)
);
);
$default_mailbox_template = array(
"template" => "Default",
"type" => "mailbox",
Expand Down Expand Up @@ -1424,7 +1424,7 @@ function init_db_schema() {
"acl_quarantine_category" => 1,
"acl_app_passwds" => 1,
)
);
);
$stmt = $pdo->prepare("SELECT id FROM `templates` WHERE `type` = :type AND `template` = :template");
$stmt->execute(array(
":type" => "domain",
Expand All @@ -1438,8 +1438,8 @@ function init_db_schema() {
":type" => "domain",
":template" => $default_domain_template["template"],
":attributes" => json_encode($default_domain_template["attributes"])
));
}
));
}
$stmt = $pdo->prepare("SELECT id FROM `templates` WHERE `type` = :type AND `template` = :template");
$stmt->execute(array(
":type" => "mailbox",
Expand All @@ -1453,8 +1453,8 @@ function init_db_schema() {
":type" => "mailbox",
":template" => $default_mailbox_template["template"],
":attributes" => json_encode($default_mailbox_template["attributes"])
));
}
));
}

if (php_sapi_name() == "cli") {
echo "DB initialization completed" . PHP_EOL;
Expand Down

0 comments on commit 59b6655

Please sign in to comment.