Passed
Pull Request — 2.x (#77)
by
unknown
03:01
created
src/H5app/Client.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     {
59 59
         $nonceStr = $this->getNonceStr();
60 60
         $timeStamp = time();
61
-        $plain = 'jsapi_ticket=' . $this->getTicket() . '&noncestr=' . $nonceStr . '&timestamp=' . $timeStamp . '&url=' . $url;
61
+        $plain = 'jsapi_ticket='.$this->getTicket().'&noncestr='.$nonceStr.'&timestamp='.$timeStamp.'&url='.$url;
62 62
         $signature = sha1($plain);
63 63
         return [
64 64
             'agentId' => $this->app['config']->get('agent_id'),
@@ -85,9 +85,9 @@  discard block
 block discarded – undo
85 85
      *
86 86
      * @return string
87 87
      */
88
-    protected function getNonceStr($length=16)
88
+    protected function getNonceStr($length = 16)
89 89
     {
90 90
         $strs = "QWERTYUIOPASDFGHJKLZXCVBNM1234567890qwertyuiopasdfghjklzxcvbnm";
91
-        return substr(str_shuffle($strs), mt_rand(0, strlen($strs)-11), $length);
91
+        return substr(str_shuffle($strs), mt_rand(0, strlen($strs) - 11), $length);
92 92
     }
93 93
 }
Please login to merge, or discard this patch.
src/H5app/ServiceProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
      */
26 26
     public function register(Container $pimple)
27 27
     {
28
-        $pimple['h5app'] = function ($app) {
28
+        $pimple['h5app'] = function($app) {
29 29
             return new Client($app);
30 30
         };
31 31
     }
Please login to merge, or discard this patch.