Passed
Push — develop ( fcd18c...7888af )
by Septianata
11:22
created
database/migrations/2021_05_22_000008_create_customers_table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
      */
18 18
     public function up()
19 19
     {
20
-        Schema::create('customers', function (Blueprint $table) {
20
+        Schema::create('customers', function(Blueprint $table) {
21 21
             $table->id();
22 22
 
23 23
             $table->string('telegram_chat_id');
Please login to merge, or discard this patch.
database/migrations/2021_05_22_000005_create_configurations_table.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
     public function up()
18 18
     {
19
-        Schema::create('configurations', function (Blueprint $table) {
19
+        Schema::create('configurations', function(Blueprint $table) {
20 20
             $table->id();
21 21
 
22 22
             $table->string('key')->unique();
Please login to merge, or discard this patch.
database/migrations/2021_05_22_000012_create_items_table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
      */
19 19
     public function up()
20 20
     {
21
-        Schema::create('items', function (Blueprint $table) {
21
+        Schema::create('items', function(Blueprint $table) {
22 22
             $table->id();
23 23
             $table->foreignIdFor(Order::class)->constrained()->onUpdate('cascade')->onDelete('cascade');
24 24
             $table->foreignIdFor(Denomination::class)->constrained()->onUpdate('cascade')->onDelete('cascade');
Please login to merge, or discard this patch.
database/seeders/ConfigurationSeeder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
      */
15 15
     public function run()
16 16
     {
17
-        array_map(fn (array $attributes) => Configuration::create($attributes), [
17
+        array_map(fn(array $attributes) => Configuration::create($attributes), [
18 18
             [
19 19
                 'key' => 'maximum_total_order_value',
20 20
                 'value' => 44000000,
Please login to merge, or discard this patch.
app/Console/Commands/NodeModulesLink.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@
 block discarded – undo
26 26
         $link = public_path('node_modules');
27 27
         $target = base_path('node_modules');
28 28
 
29
-        if (file_exists($link) && ! $this->isRemovableSymlink($link, $this->option('force'))) {
29
+        if (file_exists($link) && !$this->isRemovableSymlink($link, $this->option('force'))) {
30 30
             return $this->error("The [$link] link already exists.");
31 31
         }
32 32
 
Please login to merge, or discard this patch.
app/Providers/RouteServiceProvider.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     {
38 38
         $this->configureRateLimiting();
39 39
 
40
-        $this->routes(function () {
40
+        $this->routes(function() {
41 41
             Route::prefix('api')
42 42
                 ->middleware('api')
43 43
                 ->namespace($this->namespace)
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
                 ->namespace($this->namespace)
48 48
                 ->group(base_path('routes/web.php'));
49 49
 
50
-            Route::match(['get', 'post'], '/botman', function () {
50
+            Route::match([ 'get', 'post' ], '/botman', function() {
51 51
                 $this->mapBotManCommands();
52 52
             })->middleware('web_without_csrf');
53 53
         });
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
      */
61 61
     protected function configureRateLimiting()
62 62
     {
63
-        RateLimiter::for('api', function (Request $request) {
63
+        RateLimiter::for ('api', function(Request $request) {
64 64
             return Limit::perMinute(60)->by(optional($request->user())->id ?: $request->ip());
65 65
         });
66 66
     }
Please login to merge, or discard this patch.
app/Http/Resources/DataTables/OrderResource.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
         return [
21 21
             'checkbox' => view('components.datatables.checkbox', [
22
-                'id' => 'order_' . $this->resource->getKey(),
22
+                'id' => 'order_'.$this->resource->getKey(),
23 23
             ])->render(),
24 24
             'code' => $this->resource->code,
25 25
             'customer_fullname' => view('components.datatables.link', [
Please login to merge, or discard this patch.
app/Models/Order.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,6 +48,6 @@
 block discarded – undo
48 48
     {
49 49
         $date ??= Carbon::today();
50 50
 
51
-        return $prefix . '-' . $date->format('Ymd') . '-' . Str::random(5);
51
+        return $prefix.'-'.$date->format('Ymd').'-'.Str::random(5);
52 52
     }
53 53
 }
Please login to merge, or discard this patch.
app/Conversations/ExchangeConversation.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -74,12 +74,12 @@  discard block
 block discarded – undo
74 74
                 Button::create(view('conversations.register-customer.reply-customer_data-no')->render())->value('no'),
75 75
             ]);
76 76
 
77
-        return $this->ask($question, next: function (Answer $answer) use ($customer) {
77
+        return $this->ask($question, next: function(Answer $answer) use ($customer) {
78 78
             if (!$answer->isInteractiveMessageReply()) {
79 79
                 return;
80 80
             }
81 81
 
82
-            if (!in_array($value = $answer->getValue(), ['yes', 'no'])) {
82
+            if (!in_array($value = $answer->getValue(), [ 'yes', 'no' ])) {
83 83
                 return $this->displayCustomerData($customer, $this->fallbackMessage($answer->getText()));
84 84
             }
85 85
 
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
             $additionalParameters = $keyboard->toArray()
121 121
         );
122 122
 
123
-        return $this->getBot()->storeConversation($this, next: function (Answer $answer) use ($response, $customer, $denominations) {
123
+        return $this->getBot()->storeConversation($this, next: function(Answer $answer) use ($response, $customer, $denominations) {
124 124
             if (!$answer->isInteractiveMessageReply()) {
125 125
                 return;
126 126
             }
@@ -131,18 +131,18 @@  discard block
 block discarded – undo
131 131
             }
132 132
 
133 133
             /** @var \App\Models\Order $order */
134
-            $order = Order::where('code', $this->getUserStorage('order_code'))->firstOr(function () use ($customer) {
134
+            $order = Order::where('code', $this->getUserStorage('order_code'))->firstOr(function() use ($customer) {
135 135
                 $order = new Order;
136 136
 
137 137
                 $order->setCustomerRelationValue($customer)->save();
138 138
 
139
-                $orderStatus = new ModelOrderStatus(['status' => EnumOrderStatus::draft()]);
139
+                $orderStatus = new ModelOrderStatus([ 'status' => EnumOrderStatus::draft() ]);
140 140
 
141 141
                 $order->statuses()->save(
142 142
                     $orderStatus->setIssuerableRelationValue($customer)
143 143
                 );
144 144
 
145
-                $this->setUserStorage(['order_code' => $order->code]);
145
+                $this->setUserStorage([ 'order_code' => $order->code ]);
146 146
 
147 147
                 return $order;
148 148
             });
Please login to merge, or discard this patch.