Pretty print SQL

This commit is contained in:
Alex Cabal 2022-12-24 15:44:42 -06:00
parent 31a8bc2d6c
commit 26a24cdbe2
17 changed files with 316 additions and 82 deletions

View file

@ -26,7 +26,12 @@ try{
// Certain user agents may bypass login entirely
$isUserAgentAllowed = false;
if(isset($_SERVER['HTTP_USER_AGENT'])){
$isUserAgentAllowed = Db::QueryInt('select count(*) from FeedUserAgents where instr(?, UserAgent) limit 1', [$_SERVER['HTTP_USER_AGENT']]);
$isUserAgentAllowed = Db::QueryInt('
SELECT count(*)
from FeedUserAgents
where instr(?, UserAgent)
limit 1
', [$_SERVER['HTTP_USER_AGENT']]);
}
if(!$isUserAgentAllowed){