Completed
Push — master ( 89cd87...82e012 )
by Tomas
02:29
created
src/Presenters/ApiPresenter.php 3 patches
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,6 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 namespace Tomaj\NetteApi\Presenters;
4 4
 
5
+use Exception;
5 6
 use Nette\Application\Responses\JsonResponse;
6 7
 use Nette\Application\UI\Presenter;
7 8
 use Nette\Http\Response;
@@ -9,7 +10,6 @@  discard block
 block discarded – undo
9 10
 use Tomaj\NetteApi\ApiResponse;
10 11
 use Tomaj\NetteApi\Misc\IpDetectorInterface;
11 12
 use Tomaj\NetteApi\Params\ParamsProcessor;
12
-use Exception;
13 13
 
14 14
 class ApiPresenter extends Presenter
15 15
 {
Please login to merge, or discard this patch.
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -107,6 +107,9 @@
 block discarded – undo
107 107
         return $paramsProcessor->getValues();
108 108
     }
109 109
 
110
+    /**
111
+     * @param double $elapsed
112
+     */
110 113
     private function logRequest($logger, $code, $elapsed)
111 114
     {
112 115
         $headers = [];
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
         $end = microtime(true);
69 69
 
70 70
         if ($this->context->hasService('apiLogger')) {
71
-            $this->logRequest($this->context->getService('apiLogger'), $code, $end-$start);
71
+            $this->logRequest($this->context->getService('apiLogger'), $code, $end - $start);
72 72
         }
73 73
 
74 74
         // output to nette
Please login to merge, or discard this patch.