Jelajahi Sumber

Add REQUEST_TIME_FLOAT
compatible with php 5.4 and useful for benchmarks

Joanhey 6 tahun lalu
induk
melakukan
001d8b13d6
1 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 2 1
      Protocols/Http.php

+ 2 - 1
Protocols/Http.php

@@ -109,7 +109,8 @@ class Http
             'CONTENT_TYPE'         => '',
             'REMOTE_ADDR'          => '',
             'REMOTE_PORT'          => '0',
-            'REQUEST_TIME'         => \time()
+            'REQUEST_TIME'         => \time(),
+            'REQUEST_TIME_FLOAT'   => \microtime(true) //compatible php5.4
         );
 
         // Parse headers.