DB backend: just log errors

Change-Id: Iab25ef50aae5a84b309aeabd0d470da6ea9dd023
diff --git a/db_backend.php b/db_backend.php
index 9e4bec5..fa587ef 100644
--- a/db_backend.php
+++ b/db_backend.php
@@ -63,7 +63,7 @@
             }
             return $persons;
         } catch (PDOException $pe) {
-            trigger_error('Could not connect to MySQL database. ' . $pe->getMessage(), E_USER_ERROR);
+            $this->log->error("Could perform query `$sql´: " . $pe->getMessage());
         }
     }
 
@@ -88,7 +88,7 @@
             $row = $stmt->fetch(PDO::FETCH_ASSOC);
             return $row['COUNT(*)'];
         } catch (PDOException $pe) {
-            trigger_error('Could not connect to MySQL database. ' . $pe->getMessage(), E_USER_ERROR);
+            $this->log->error("Could perform query `$sql´: " . $pe->getMessage());
         }
     }
 
@@ -101,7 +101,7 @@
             $row = $stmt->fetch(PDO::FETCH_ASSOC);
             return $row['COUNT(*)'];
         } catch (PDOException $pe) {
-            trigger_error('Could not connect to MySQL database. ' . $pe->getMessage(), E_USER_ERROR);
+            $this->log->error("Could perform query `$sql´: " . $pe->getMessage());
         }
     }
 
@@ -120,7 +120,7 @@
             }
             return $persons;
         } catch (PDOException $pe) {
-            trigger_error('Could not connect to MySQL database. ' . $pe->getMessage(), E_USER_ERROR);
+            $this->log->error("Could perform query `$sql´: " . $pe->getMessage());
         }
     }
 }