Skip to content

Commit

Permalink
fix: added missing check on current user object, closes #3302
Browse files Browse the repository at this point in the history
  • Loading branch information
thorsten committed Dec 28, 2024
1 parent ff12896 commit d11381b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion phpmyfaq/src/phpMyFAQ/Session.php
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ public function userTracking(string $action, int|string|null $data = null): void
"INSERT INTO %sfaqsessions (sid, user_id, ip, time) VALUES (%d, %d, '%s', %d)",
Database::getTablePrefix(),
$this->getCurrentSessionId(),
$this->currentUser->getUserId(),
isset($this->currentUser) ? $this->currentUser->getUserId() : 0,
$remoteAddress,
$request->server->get('REQUEST_TIME')
);
Expand Down

0 comments on commit d11381b

Please sign in to comment.