Skip to content

Commit

Permalink
fix: added missing column for MS SQL and SQLite3
Browse files Browse the repository at this point in the history
  • Loading branch information
thorsten committed Aug 22, 2024
1 parent 1e8d677 commit c40bb77
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ public function install(): Response

/**
* @throws TemplateException
* @throws Exception
*/
#[Route('/setup/update', name: 'public.setup.update')]
public function update(Request $request): Response
Expand Down
1 change: 1 addition & 0 deletions phpmyfaq/src/phpMyFAQ/Instance/Database/Sqlite3.php
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ class Sqlite3 extends Database implements Driver
date_end VARCHAR(14) NOT NULL DEFAULT \'99991231235959\',
created DATETIME DEFAULT CURRENT_TIMESTAMP,
notes text DEFAULT NULL,
sticky_order INTEGER DEFAULT NULL,
PRIMARY KEY (id, lang))',

'faqdata_revisions' => 'CREATE TABLE %sfaqdata_revisions (
Expand Down
1 change: 1 addition & 0 deletions phpmyfaq/src/phpMyFAQ/Instance/Database/Sqlsrv.php
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ class Sqlsrv extends Database implements Driver
date_end NVARCHAR(14) NOT NULL DEFAULT \'99991231235959\',
created DATETIME DEFAULT CURRENT_TIMESTAMP,
notes NVARCHAR(MAX) DEFAULT NULL,
sticky_order INTEGER DEFAULT NULL,
PRIMARY KEY (id, lang, solution_id, revision_id))',

'faqdata_group' => 'CREATE TABLE %sfaqdata_group (
Expand Down
2 changes: 1 addition & 1 deletion phpmyfaq/src/phpMyFAQ/Setup/Installer.php
Original file line number Diff line number Diff line change
Expand Up @@ -846,7 +846,7 @@ public function startInstall(array|null $setup = null): void
INPUT_POST,
'sql_sqlitefile',
FILTER_SANITIZE_SPECIAL_CHARS,
$setup['dbServer']
$setup['dbServer'] ?? null
);
if (is_null($dbSetup['dbServer'])) {
throw new Exception('Installation Error: Please add a SQLite database filename.');
Expand Down

0 comments on commit c40bb77

Please sign in to comment.