File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -222,12 +222,12 @@ public function order(): Filter
222222 $ direction = $ sortBy ->get ($ value ) ?? $ defaultDirection ;
223223 return [$ value => $ direction ];
224224 }
225+
225226 if (is_array ($ value )) {
226227 return collect ($ value )->mapWithKeys (static fn ($ value ): array => [$ value => $ key ])->toArray ();
227228 }
228- else {
229- return [$ value => $ key ];
230- }
229+
230+ return [$ value => $ key ];
231231 })->toArray ();
232232 } else {
233233 $ orderBy [strtolower ((string ) $ orderValues )] = strtolower ((string ) $ defaultDirection );
Original file line number Diff line number Diff line change @@ -95,9 +95,11 @@ private function compile(): void
9595 if (!isset ($ config ['aliases ' ])) {
9696 continue ;
9797 }
98+
9899 if (!is_array ($ config ['aliases ' ])) {
99100 continue ;
100101 }
102+
101103 array_walk ($ config ['aliases ' ], static function ($ alias ) use (&$ parameters , $ config ): void {
102104 $ parameters [$ alias ] = $ config ;
103105 });
Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ public function strategyManager(): StrategyManager
4848 return new StrategyManager ;
4949 }
5050
51- public function getRawSqlFromBuilder (Builder $ builder )
51+ public function getRawSqlFromBuilder (Builder $ builder ): string
5252 {
5353 $ query = str_replace (['? ' ], ["'%s' " ], $ builder ->toSql ());
5454 return vsprintf ($ query , $ builder ->getBindings ());
You can’t perform that action at this time.
0 commit comments