Pārlūkot izejas kodu

Use native MySQL types

Alan Lam 2 gadi atpakaļ
vecāks
revīzija
d6ccbb2556
1 mainītis faili ar 2 papildinājumiem un 0 dzēšanām
  1. 2 0
      engine/db.php

+ 2 - 0
engine/db.php

@@ -25,6 +25,8 @@ class DB {
 	 */
 	public static function connect(string $host, string $username, string $password, string $database = "", int $port = 3306): mysqli {
 		$link = @new mysqli($host, $username, $password, $database, $port);
+		$link->options(MYSQLI_OPT_INT_AND_FLOAT_NATIVE, 1);
+
 		self::$DB = $link;
 
 		if(!is_null($link->connect_error)) {