Skip to content

Commit

Permalink
strict fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Dec 9, 2020
1 parent 458bb14 commit 5d9637e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Tracy/Bar/Bar.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ public function dispatchAssets(): bool
header('X-Tracy-Ajax: 1'); // session must be already locked
}

if ($this->useSession && $asset && preg_match('#^content(-ajax)?\.(\w+)$#', $asset, $m)) {
if ($this->useSession && is_string($asset) && preg_match('#^content(-ajax)?\.(\w+)$#', $asset, $m)) {
$session = &$_SESSION['_tracy']['bar'][$m[2]];
header('Content-Type: application/javascript; charset=UTF-8');
header('Cache-Control: max-age=60');
Expand Down

0 comments on commit 5d9637e

Please sign in to comment.