Passed
Push — master ( f69e80...b82761 )
by Matthijs
07:44 queued 03:22
created
src/Middleware/DetectShopDomain.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
     {
17 17
         $shop = ShopService::findUrl($request->root());
18 18
 
19
-        if(!$shop) {
19
+        if (!$shop) {
20 20
             abort(404, "shop cannot be found");
21 21
         }
22 22
 
Please login to merge, or discard this patch.
src/Services/Coupon/CouponService.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -9,10 +9,10 @@
 block discarded – undo
9 9
  
10 10
 class CouponService extends BaseService
11 11
 {
12
-	public function __construct(CouponRepository $coupon)
13
-	{
14
-		$this->repo = $coupon;
15
-	}
12
+    public function __construct(CouponRepository $coupon)
13
+    {
14
+        $this->repo = $coupon;
15
+    }
16 16
 
17 17
     /**
18 18
      * The validation rules for the model.
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,8 +30,8 @@  discard block
 block discarded – undo
30 30
         );
31 31
         
32 32
         if ($couponId) {
33
-            $rules['title'] =   'required|between:4,65|unique_with:'.$this->repo->getModel()->getTable().', shop_id, '.$couponId.' = id';
34
-            $rules['code'] =   'required|between:4,65|unique_with:'.$this->repo->getModel()->getTable().', shop_id, '.$couponId.' = id';
33
+            $rules['title'] = 'required|between:4,65|unique_with:'.$this->repo->getModel()->getTable().', shop_id, '.$couponId.' = id';
34
+            $rules['code'] = 'required|between:4,65|unique_with:'.$this->repo->getModel()->getTable().', shop_id, '.$couponId.' = id';
35 35
         }
36 36
 
37 37
         return $rules;
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
         );
45 45
         
46 46
         if ($groupId) {
47
-            $rules['title'] =   'required|between:4,65|unique_with:'.$this->repo->getGroupModel()->getTable().', shop_id, '.$groupId.' = id';
47
+            $rules['title'] = 'required|between:4,65|unique_with:'.$this->repo->getGroupModel()->getTable().', shop_id, '.$groupId.' = id';
48 48
         }
49 49
 
50 50
         return $rules;
Please login to merge, or discard this patch.
src/Services/BaseService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
     {
40 40
         if (isset($result->id)) {
41 41
             Notification::success($successMsg);
42
-            if(is_array($routeName)) {
42
+            if (is_array($routeName)) {
43 43
                 return redirect()->route($routeName[0], $routeName[1]);
44 44
             }
45 45
             return redirect()->route($routeName);   
Please login to merge, or discard this patch.
src/Services/Exception/ExceptionService.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -7,8 +7,8 @@
 block discarded – undo
7 7
  
8 8
 class ExceptionService extends BaseService
9 9
 {
10
-	public function __construct(ExceptionItemRepository $exception)
11
-	{
12
-		$this->repo = $exception;
13
-	} 
10
+    public function __construct(ExceptionItemRepository $exception)
11
+    {
12
+        $this->repo = $exception;
13
+    } 
14 14
 }
15 15
\ No newline at end of file
Please login to merge, or discard this patch.
src/Services/BaseRepository.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -4,19 +4,19 @@
 block discarded – undo
4 4
  
5 5
 class BaseRepository 
6 6
 {
7
-	public function selectAll()
8
-	{
9
-	    return $this->model->where('shop_id', auth('hideyobackend')->user()->selected_shop_id)->get();
10
-	}
7
+    public function selectAll()
8
+    {
9
+        return $this->model->where('shop_id', auth('hideyobackend')->user()->selected_shop_id)->get();
10
+    }
11 11
 
12 12
     public function selectAllByShopId($shopId)
13 13
     {
14
-         return $this->model->where('shop_id', $shopId)->get();
14
+            return $this->model->where('shop_id', $shopId)->get();
15 15
     }
16 16
 
17 17
     public function selectAllActiveByShopId($shopId)
18 18
     {
19
-         return $this->model->where('shop_id', $shopId)->where('active', 1)->get();
19
+            return $this->model->where('shop_id', $shopId)->where('active', 1)->get();
20 20
     }
21 21
 
22 22
     public function getModel() {
Please login to merge, or discard this patch.
src/Services/SendingMethod/Entity/SendingMethodRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
     public function selectOneByShopIdAndId($shopId, $sendingMethodId)
21 21
     {
22 22
         return $this->model->with(
23
-            array('relatedPaymentMethods' => function ($query) {
23
+            array('relatedPaymentMethods' => function($query) {
24 24
                 $query->where('active', 1);
25 25
             })
26 26
         )->where('shop_id', $shopId)->where('active', 1)
Please login to merge, or discard this patch.
src/Services/Faq/Entity/FaqItemRepository.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,6 +32,6 @@
 block discarded – undo
32 32
 
33 33
     function selectAllActiveByShopId($shopId)
34 34
     {
35
-         return $this->model->where('shop_id', $shopId)->get();
35
+            return $this->model->where('shop_id', $shopId)->get();
36 36
     }      
37 37
 }
38 38
\ No newline at end of file
Please login to merge, or discard this patch.
src/Services/Order/Entity/OrderStatusEmailTemplateRepository.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -20,10 +20,10 @@
 block discarded – undo
20 20
 
21 21
     public function selectBySendingMethodIdAndPaymentMethodId($paymentMethodId, $sendingMethodId)
22 22
     {
23
-        $result = $this->model->with(array('sendingPaymentMethodRelated' => function ($query) use ($paymentMethodId, $sendingMethodId) {
24
-            $query->with(array('sendingMethod' => function ($query) use ($sendingMethodId) {
23
+        $result = $this->model->with(array('sendingPaymentMethodRelated' => function($query) use ($paymentMethodId, $sendingMethodId) {
24
+            $query->with(array('sendingMethod' => function($query) use ($sendingMethodId) {
25 25
                 $query->where('id', $sendingMethodId);
26
-            }, 'paymentMethod' => function ($query) use ($paymentMethodId) {
26
+            }, 'paymentMethod' => function($query) use ($paymentMethodId) {
27 27
                 $query->where('id', $paymentMethodId);
28 28
             }));
29 29
         } ))
Please login to merge, or discard this patch.
src/Services/Order/Entity/OrderRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@
 block discarded – undo
75 75
 
76 76
     public function orderProductsByClientId($clientId, $shopId)
77 77
     {
78
-        return $this->modelOrderProduct->with(array('product'))->whereHas('Order', function ($query) use ($clientId, $shopId) {
78
+        return $this->modelOrderProduct->with(array('product'))->whereHas('Order', function($query) use ($clientId, $shopId) {
79 79
             $query->where('client_id', '=', $clientId)->where('shop_id', $shopId);
80 80
         });
81 81
     }
Please login to merge, or discard this patch.