Skip to content

Commit

Permalink
remove non required sql requests
Browse files Browse the repository at this point in the history
```
SELECT `appid`, `configkey`, `configvalue` FROM `preferences` WHERE `userid` = '';
```
  • Loading branch information
Loki3000 authored Jan 10, 2017
1 parent 8ab16f8 commit 7e06f05
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions lib/private/AllConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -358,12 +358,17 @@ public function deleteAppFromAllUsers($appName) {
* ]
*/
private function getUserValues($userId) {
// TODO - FIXME
$this->fixDIInit();

if (isset($this->userCache[$userId])) {
return $this->userCache[$userId];
}
if ($userId === null || $userId === '') {
$this->userCache[$userId]=array();
return $this->userCache[$userId];
}

// TODO - FIXME
$this->fixDIInit();

$data = array();
$query = 'SELECT `appid`, `configkey`, `configvalue` FROM `*PREFIX*preferences` WHERE `userid` = ?';
$result = $this->connection->executeQuery($query, array($userId));
Expand Down

0 comments on commit 7e06f05

Please sign in to comment.