@@ -178,11 +178,11 @@ public function registerPlugins(string $providerPath): void
178178 $ newPlugins = '' ;
179179
180180 foreach ($ pluginsToAdd as $ plugin ) {
181- $ searchPlugin = '/ ' . $ plugin . '/ ' ;
181+ $ searchPlugin = '/ ' . $ plugin. '/ ' ;
182182 if (preg_match ($ searchPlugin , $ content )) {
183183 warning ("$ plugin already registered. " );
184184 } else {
185- $ newPlugins .= $ intend . $ namespace . '\\' . $ plugin . $ function . "\n" ;
185+ $ newPlugins .= $ intend. $ namespace. '\\' . $ plugin. $ function. "\n" ;
186186 }
187187 }
188188
@@ -197,7 +197,7 @@ public function registerPlugins(string $providerPath): void
197197
198198 $ pluginsSection = " ->plugins([ \n$ newPlugins \n ]); " ;
199199 $ placeholderPattern = '/(\->authMiddleware\(\[.*?\]\))\s*\;/s ' ;
200- $ replacement = "$1 \n" . $ pluginsSection ;
200+ $ replacement = "$1 \n" . $ pluginsSection ;
201201 $ newContent = preg_replace ($ placeholderPattern , $ replacement , $ content , 1 );
202202 }
203203 File::put ($ providerPath , $ newContent );
@@ -208,15 +208,14 @@ public function registerPlugins(string $providerPath): void
208208 }
209209
210210 public function registerPluginInPanelProvider (): void
211-
212211 {
213212 $ providerPath = app_path ('Providers/Filament ' );
214213 $ panelsToregister = $ this ->getPanelProviderPath ();
215214 if ($ panelsToregister != null ) {
216215 if (is_array ($ panelsToregister )) {
217216 //Multiselect
218217 foreach ($ panelsToregister as $ panelprovider ) {
219- $ this ->registerPlugins ($ providerPath . '/ ' . $ panelprovider );
218+ $ this ->registerPlugins ($ providerPath. '/ ' . $ panelprovider );
220219 }
221220 } else {
222221 //only one
@@ -243,7 +242,7 @@ public function getPanelProviderPath(): string|array
243242 );
244243 }
245244 if (count ($ providers ) == 1 ) {
246- $ providerPath .= '/ ' . $ providers [0 ]->getBasename ();
245+ $ providerPath .= '/ ' . $ providers [0 ]->getBasename ();
247246 }
248247
249248 return $ providerPath ;
0 commit comments