From: Nicolas LÅ“uillet Date: Wed, 20 Nov 2013 09:22:21 +0000 (+0100) Subject: Fix Undefined offset Notice (thx @vjousse) X-Git-Tag: 1.2.0~1^2 X-Git-Url: https://git.immae.eu/?a=commitdiff_plain;h=0c2f453750b742fde21ec2a8fdcf3beb9eff2faf;p=github%2Fwallabag%2Fwallabag.git Fix Undefined offset Notice (thx @vjousse) --- diff --git a/inc/poche/Database.class.php b/inc/poche/Database.class.php index 1d3ff0c2..bf67de2a 100644 --- a/inc/poche/Database.class.php +++ b/inc/poche/Database.class.php @@ -166,7 +166,7 @@ class Database { $query = $this->executeQuery($sql, $params); $entry = $query->fetchAll(); - return $entry[0]; + return isset($entry[0]) ? $entry[0] : null; } public function getEntriesByView($view, $user_id, $limit = '') {