Skip to content

Commit

Permalink
sanitized username for logging functions
Browse files Browse the repository at this point in the history
  • Loading branch information
causefx committed Apr 10, 2022
1 parent 4ce478d commit a42ed9f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions api/functions/log-functions.php
Expand Up @@ -211,6 +211,9 @@ public function setLoggerChannel($channel = 'Organizr', $username = null)
{
if ($this->hasDB()) {
$setLogger = false;
if ($username) {
$username = filter_var($username, FILTER_SANITIZE_STRING);
}
if ($this->logger) {
if ($channel) {
if (strtolower($this->logger->getChannel()) !== strtolower($channel)) {
Expand Down

0 comments on commit a42ed9f

Please sign in to comment.