Bug fix for PDO fetch method