Skip to content

Commit

Permalink
Fix $this->config to $config bug in Cli controller.
Browse files Browse the repository at this point in the history
  • Loading branch information
mark-unwin committed Dec 11, 2023
1 parent 5a9dca5 commit 8d05893
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Controllers/Cli.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public function executeTasks()
$response->meta = new stdClass();
$response->meta->collection = 'tasks';
$response->meta->action = 'execute';
$response->meta->uuid = $this->config->uuid;
$response->meta->uuid = $config->uuid;
$db = db_connect() or die("Cannot establish a database connection.");
// Insert the entry
$sql = "INSERT INTO enterprise VALUES (null, ?, '', NOW(), '')";
Expand Down Expand Up @@ -231,7 +231,7 @@ public function cloudDevice($id)
log_message('error', 'A cloud Device request received, but no device was present in the request.');
}
helper('device');
$this->config = new \Config\OpenAudit();
$config = new \Config\OpenAudit();
$db = db_connect() or die("Cannot establish a database connection.");
$sql = "SELECT * FROM enterprise WHERE id = ?";
$result = $db->query($sql, [$id])->getResult();
Expand Down

0 comments on commit 8d05893

Please sign in to comment.