Passed
Pull Request — master (#83)
by Бабичев
10:32
created
src/Services/LockService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     public function lock($self, string $name, \Closure $closure)
21 21
     {
22
-        return $this->lockProvider($self, $name, (int)config('wallet.lock.seconds'))
22
+        return $this->lockProvider($self, $name, (int) config('wallet.lock.seconds'))
23 23
             ->get($this->bindTo($self, $closure));
24 24
     }
25 25
 
Please login to merge, or discard this patch.
src/Commands/RefreshBalance.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
     public function handle(): void
39 39
     {
40 40
         app(ProxyService::class)->fresh();
41
-        DB::transaction(function() {
41
+        DB::transaction(function () {
42 42
             $wallet = config('wallet.wallet.table');
43 43
             DB::table($wallet)->update(['balance' => 0]);
44 44
 
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
             ->where('confirmed', true)
77 77
             ->groupBy('wallet_id');
78 78
 
79
-        $joinClause = static function(JoinClause $join) use ($wallet) {
79
+        $joinClause = static function (JoinClause $join) use ($wallet) {
80 80
             $join->on("$wallet.id", '=', 'b.wallet_id');
81 81
         };
82 82
 
Please login to merge, or discard this patch.
src/Traits/HasWallet.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
     public function deposit(int $amount, ?array $meta = null, bool $confirmed = true): Transaction
42 42
     {
43 43
         $self = $this;
44
-        return DB::transaction(static function() use ($self, $amount, $meta, $confirmed) {
44
+        return DB::transaction(static function () use ($self, $amount, $meta, $confirmed) {
45 45
             return app(CommonService::class)
46 46
                 ->deposit($self, $amount, $meta, $confirmed);
47 47
         });
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
     public function forceWithdraw(int $amount, ?array $meta = null, bool $confirmed = true): Transaction
166 166
     {
167 167
         $self = $this;
168
-        return DB::transaction(static function() use ($self, $amount, $meta, $confirmed) {
168
+        return DB::transaction(static function () use ($self, $amount, $meta, $confirmed) {
169 169
             return app(CommonService::class)
170 170
                 ->forceWithdraw($self, $amount, $meta, $confirmed);
171 171
         });
@@ -183,7 +183,7 @@  discard block
 block discarded – undo
183 183
     public function forceTransfer(Wallet $wallet, int $amount, ?array $meta = null): Transfer
184 184
     {
185 185
         $self = $this;
186
-        return DB::transaction(static function() use ($self, $amount, $wallet, $meta) {
186
+        return DB::transaction(static function () use ($self, $amount, $wallet, $meta) {
187 187
             return app(CommonService::class)
188 188
                 ->forceTransfer($self, $wallet, $amount, $meta);
189 189
         });
Please login to merge, or discard this patch.
src/Traits/CartPay.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
             ->verifyWithdraw($this, 0, true);
33 33
 
34 34
         $self = $this;
35
-        return DB::transaction(static function() use ($self, $cart) {
35
+        return DB::transaction(static function () use ($self, $cart) {
36 36
             $results = [];
37 37
             foreach ($cart->getItems() as $product) {
38 38
                 $results[] = app(CommonService::class)->forceTransfer(
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
         }
76 76
 
77 77
         $self = $this;
78
-        return DB::transaction(static function() use ($self, $cart, $force) {
78
+        return DB::transaction(static function () use ($self, $cart, $force) {
79 79
             $results = [];
80 80
             foreach ($cart->getItems() as $product) {
81 81
                 if ($force) {
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
     public function refundCart(Cart $cart, bool $force = null, bool $gifts = null): bool
139 139
     {
140 140
         $self = $this;
141
-        return DB::transaction(static function() use ($self, $cart, $force, $gifts) {
141
+        return DB::transaction(static function () use ($self, $cart, $force, $gifts) {
142 142
             $results = [];
143 143
             $transfers = $cart->alreadyBuy($self, $gifts);
144 144
             if (count($transfers) !== count($cart)) {
Please login to merge, or discard this patch.
src/Traits/CanConfirm.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@
 block discarded – undo
22 22
     {
23 23
         return app(LockService::class)->lock($this, __FUNCTION__, function () use ($transaction) {
24 24
             $self = $this;
25
-            return DB::transaction(static function() use ($self, $transaction) {
25
+            return DB::transaction(static function () use ($self, $transaction) {
26 26
                 $wallet = app(WalletService::class)
27 27
                     ->getWallet($self);
28 28
 
Please login to merge, or discard this patch.
src/Traits/HasGift.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
              * I think it is wrong to make the "assemble" method public.
64 64
              * That's why I address him like this!
65 65
              */
66
-            return DB::transaction(static function() use ($santa, $to, $product, $force) {
66
+            return DB::transaction(static function () use ($santa, $to, $product, $force) {
67 67
                 $amount = $product->getAmountProduct();
68 68
                 $meta = $product->getMetaProduct();
69 69
                 $fee = app(WalletService::class)
Please login to merge, or discard this patch.