Testing the return value of PDOStatement::Execute does not appear to work on MySQL.
authorRobert Sesek <rsesek@bluestatic.org>
Tue, 4 Jun 2013 05:00:52 +0000 (01:00 -0400)
committerRobert Sesek <rsesek@bluestatic.org>
Tue, 4 Jun 2013 05:00:52 +0000 (01:00 -0400)
views/pdo_cache_backend.php

index da3f0931f48c004dca109ba8530bb47d8f965c84..3ccb01cef89dba9eb0c2868b713b9c2dc14eca00 100644 (file)
@@ -70,9 +70,7 @@ class PDOCacheBackend implements CacheBackend
 
   public function GetTemplateDataForName($name, $modification_time)
   {
-    if (!$this->fetch_statement->Execute(array('name' => $name)))
-      return NULL;
-
+    $this->fetch_statement->Execute(array('name' => $name));
     $tpl = $this->fetch_statement->FetchObject();
     if (!$tpl)
       return NULL;