Explorar o código

fix numeric values being set as string

throwaway %!s(int64=2) %!d(string=hai) anos
pai
achega
d20f0fcf88
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      docker/gen_config.php

+ 3 - 0
docker/gen_config.php

@@ -25,6 +25,9 @@ function type_to_string($n) {
                 return $n ? 'true' : 'false';
         }
         if ($type === "string") {
+                if(is_numeric($n)) {
+                        return $n;
+                }
                 return "\"$n\"";
         }
         if ($type === "array") {