@@ -116,7 +116,7 @@ public function get($limit = 0, $offet = 0)
116116 static ::$ response ["response " ] = "Parameter limit should be numeric function get() " ;
117117 static ::$ response ["code " ] = 6000 ;
118118
119- $ this -> terminate (static ::$ response );
119+ return static :: terminate (static ::$ response );
120120 }
121121
122122 //check if the offsel is a number
@@ -125,7 +125,7 @@ public function get($limit = 0, $offet = 0)
125125 static ::$ response ["response " ] = "Parameter offset should be numeric in function get() " ;
126126 static ::$ response ["code " ] = 6001 ;
127127
128- $ this -> terminate (static ::$ response );
128+ return static :: terminate (static ::$ response );
129129 }
130130
131131 $ table_name = self ::$ table ;
@@ -344,7 +344,7 @@ protected function doInsert()
344344 static ::$ response ["status " ] = "error " ;
345345 static ::$ response ["response " ] = $ e ->getMessage ();
346346 static ::$ response ["code " ] = $ e ->getCode ();
347- return $ this -> terminate (static ::$ response );
347+ return static :: terminate (static ::$ response );
348348 }
349349 }
350350
@@ -360,21 +360,22 @@ public function truncate()
360360 static ::$ response ["response " ] = "success " ;
361361 static ::$ response ["code " ] = 200 ;
362362
363- return $ this -> terminate (static ::$ response );
363+ return static :: terminate (static ::$ response );
364364
365365 } catch (Exception $ e ) {
366366 static ::$ response ["status " ] = "error " ;
367367 static ::$ response ["response " ] = $ e ->getMessage ();
368368 static ::$ response ["code " ] = $ e ->getCode ();
369369
370- return $ this -> terminate (static ::$ response );
370+ return static :: terminate (static ::$ response );
371371 }
372372 }
373373
374374 /**
375375 * Executes a query that does not return any results
376376 *
377377 * @param $query
378+ * @return null|string
378379 */
379380 protected function exec ($ query )
380381 {
@@ -385,8 +386,9 @@ protected function exec($query)
385386 static ::$ response ["response " ] = $ e ->getMessage ();
386387 static ::$ response ["code " ] = $ e ->getCode ();
387388
388- static ::terminate (static ::$ response );
389+ return static ::terminate (static ::$ response );
389390 }
391+ return null ;
390392 }
391393
392394 public function drop ()
@@ -405,7 +407,7 @@ public function drop()
405407 static ::$ response ["status " ] = "error " ;
406408 static ::$ response ["response " ] = $ e ->getMessage ();
407409 static ::$ response ["code " ] = $ e ->getCode ();
408- return $ this -> terminate (static ::$ response );
410+ return static :: terminate (static ::$ response );
409411 }
410412
411413 }
0 commit comments