Completed
Pull Request — master (#33)
by Luke
07:50 queued 02:45
created
src/LaraCart.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
      */
56 56
     public function get($instance = 'default')
57 57
     {
58
-        if (empty($this->cart = \Session::get(config('laracart.cache_prefix', 'laracart').'.'.$instance))) {
58
+        if (empty($this->cart = \Session::get(config('laracart.cache_prefix', 'laracart') . '.' . $instance))) {
59 59
             $this->cart = new Cart($instance);
60 60
         }
61 61
 
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
      */
68 68
     public function update()
69 69
     {
70
-        \Session::set(config('laracart.cache_prefix', 'laracart').'.'.$this->cart->instance, $this->cart);
70
+        \Session::set(config('laracart.cache_prefix', 'laracart') . '.' . $this->cart->instance, $this->cart);
71 71
 
72 72
         \Event::fire('laracart.update', $this->cart);
73 73
     }
@@ -372,7 +372,7 @@  discard block
 block discarded – undo
372 372
      */
373 373
     public function addCoupon(CouponContract $coupon)
374 374
     {
375
-        if(!$this->cart->multipleCoupons) {
375
+        if (!$this->cart->multipleCoupons) {
376 376
             $this->cart->coupons = [];
377 377
         }
378 378
 
@@ -388,8 +388,8 @@  discard block
 block discarded – undo
388 388
      */
389 389
     public function removeCoupon($code)
390 390
     {
391
-        foreach($this->getItems() as $item) {
392
-            if(isset($item->code) && $item->code == $code) {
391
+        foreach ($this->getItems() as $item) {
392
+            if (isset($item->code) && $item->code == $code) {
393 393
                 $item->code = null;
394 394
                 $item->discount = null;
395 395
                 $item->couponInfo = null;
Please login to merge, or discard this patch.