You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') AND isActive = 1 ORDER BY dateRaw DESC LIMIT 0, 4' at line 3
Array
(
    [0] => Error Number: 1064
    [1] => You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') AND isActive = 1 ORDER BY dateRaw DESC LIMIT 0, 4' at line 3
    [2] => SELECT SQL_CALC_FOUND_ROWS*, photoName as photoMain , date AS dateRaw, DATE_FORMAT(date, "%M %e, %Y") AS date, (SELECT photoName FROM Photos AS PH
				JOIN Blog2Photos AS NP ON PH.photoID=NP.photoID
				WHERE NP.newsID=N.newsID ORDER BY PH.sortID LIMIT 1) AS photoName FROM BlogPosts AS N WHERE postTill >= CURDATE()  AND newsID IN (SELECT newsID FROM BlogPosts WHERE author = ) AND isActive = 1 ORDER BY dateRaw DESC LIMIT 0, 4
)