From 893f65fc02299276ca37ece7fe9cacf496930a74 Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Sun, 4 Mar 2012 13:56:12 -0600 Subject: [PATCH] Fix bundle publishing bug. If the bundle was not registered, crazy stuff would happen. We just won't publish for non-existent bundles. Signed-off-by: Taylor Otwell --- laravel/cli/tasks/bundle/publisher.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/laravel/cli/tasks/bundle/publisher.php b/laravel/cli/tasks/bundle/publisher.php index 209e8345..12527b08 100644 --- a/laravel/cli/tasks/bundle/publisher.php +++ b/laravel/cli/tasks/bundle/publisher.php @@ -14,6 +14,13 @@ class Publisher { */ public function publish($bundle) { + if ( ! Bundle::exists($bundle)) + { + echo "Bundle [$bundle] is not registered."; + + return; + } + $path = Bundle::path($bundle); $this->move($path.'public', path('public').'bundles'.DS.$bundle);