Skip to content

Commit

Permalink
Merge pull request #562 from geominorai/patch/updater/login_tokens
Browse files Browse the repository at this point in the history
Fixed updater query overlap
  • Loading branch information
Groruk authored Feb 18, 2019
2 parents 29842fd + 00ce5c3 commit a12e2a8
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions web/updater/data/700.php
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
<?php

$this->dbs->query(
"CREATE TABLE IF NOT EXISTS `:prefix_login_tokens` (
`jti` varchar(16) NOT NULL,
`secret` varchar(64) NOT NULL,
`lastAccessed` int(11) NOT NULL,
PRIMARY KEY (`jti`),
UNIQUE KEY `secret` (`secret`)
) ENGINE=InnoDB DEFAULT CHARSET=:charset;"
);

$this->dbs->bind(':charset', DB_CHARSET);

$auth = [
'auth.maxlife' => 1440,
'auth.maxlife.remember' => 10080,
Expand All @@ -25,4 +13,16 @@
$this->dbs->execute();
}

$this->dbs->query(
"CREATE TABLE IF NOT EXISTS `:prefix_login_tokens` (
`jti` varchar(16) NOT NULL,
`secret` varchar(64) NOT NULL,
`lastAccessed` int(11) NOT NULL,
PRIMARY KEY (`jti`),
UNIQUE KEY `secret` (`secret`)
) ENGINE=InnoDB DEFAULT CHARSET=:charset;"
);

$this->dbs->bind(':charset', DB_CHARSET);

return $this->dbs->execute();

0 comments on commit a12e2a8

Please sign in to comment.