Add a grep to avoid attempting to subscribe to "/queue/", which
Chris Andrews [Sun, 12 Jul 2009 17:03:05 +0000 (18:03 +0100)]
annoys ActiveMQ.

lib/Catalyst/Engine/Stomp.pm

index b94a504..2752b5e 100644 (file)
@@ -72,7 +72,8 @@ sub run {
         die 'No Engine::Stomp configuration found'
              unless ref $app->config->{'Engine::Stomp'} eq 'HASH';
 
-        my @queues = map { $app->controller($_)->action_namespace } $app->controllers;
+        my @queues = grep { length $_ }
+                    map  { $app->controller($_)->action_namespace } $app->controllers;
 
         # connect up
         my %template = %{$app->config->{'Engine::Stomp'}};