Skip to content

Commit 4f430e7

Browse files
committed
chore: add console check to publishes method
1 parent 167380d commit 4f430e7

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/Providers/IdempotencyServiceProvider.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,11 @@ public function register(): void
4242

4343
private function publishConfig(): void
4444
{
45-
$this->publishes([
46-
dirname(__DIR__, 2).'/config/idempotency.php' => config_path('idempotency.php'),
47-
], 'config');
45+
if ($this->app->runningInConsole()) {
46+
$this->publishes([
47+
dirname(__DIR__, 2).'/config/idempotency.php' => config_path('idempotency.php'),
48+
], 'config');
49+
}
4850
}
4951

5052
private function configMiddleware(): void

0 commit comments

Comments
 (0)