Skip to content
This repository has been archived by the owner on Mar 3, 2020. It is now read-only.

Commit

Permalink
I think its bad (#446)
Browse files Browse the repository at this point in the history
* Fix fail error

* Order by name in category list

The category filter in gameboard aren't ordered alphabetically

* Autofocus in team name

* Fail

* Fix Fail autofocus

* Fix error with autofocus

* Not very good

For security reasons, I think it's not very good insert the admin id by default at session table

* Update SessionTest.php
  • Loading branch information
shargon authored and gsingh93 committed Mar 21, 2017
1 parent 0b7ca09 commit d326564
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/models/Session.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ private static function sessionFromRow(Map<string, string> $row): Session {
): Awaitable<void> {
$db = await self::genDb();
await $db->queryf(
'INSERT INTO sessions (cookie, data, created_ts, last_access_ts, team_id, last_page_access) VALUES (%s, %s, NOW(), NOW(), 1, %s)',
'INSERT INTO sessions (cookie, data, created_ts, last_access_ts, team_id, last_page_access) VALUES (%s, %s, NOW(), NOW(), 0, %s)',
$cookie,
$data,
Router::getRequestedPage(),
Expand Down
2 changes: 1 addition & 1 deletion tests/models/SessionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ public function testCreate(): void {
$this->assertEquals(2, $a->getId());
$this->assertEquals('cookie2', $a->getCookie());
$this->assertEquals('data2', $a->getData());
$this->assertEquals(1, $a->getTeamId());
$this->assertEquals(0, $a->getTeamId());
}
}

0 comments on commit d326564

Please sign in to comment.