Sfoglia il codice sorgente

Update Core\DB

Track time for PDO::__construct().
Visman 3 anni fa
parent
commit
e435297865
1 ha cambiato i file con 4 aggiunte e 0 eliminazioni
  1. 4 0
      app/Core/DB.php

+ 4 - 0
app/Core/DB.php

@@ -74,8 +74,12 @@ class DB extends PDO
             self::ATTR_STATEMENT_CLASS    => [DBStatement::class, [$this]],
         ];
 
+        $start  = \microtime(true);
+
         parent::__construct($dsn, $username, $password, $options);
 
+        $this->saveQuery('PDO::__construct()', \microtime(true) - $start, false);
+
         $this->beginTransaction();
     }