[svn:p5ee] r7960 - p5ee/trunk/App-Widget-ChartDirector/lib/App/Widget

[email protected]
Newsgroups perl.cvs.p5ee
Message-ID <[email protected]>
Author: spadkins
Date: Mon Oct 23 08:32:37 2006
New Revision: 7960

Modified:
   p5ee/trunk/App-Widget-ChartDirector/lib/App/Widget/ChartDirector.pm

Log:
shorten/improve an error message

Modified: p5ee/trunk/App-Widget-ChartDirector/lib/App/Widget/ChartDirector.pm
==============================================================================
--- p5ee/trunk/App-Widget-ChartDirector/lib/App/Widget/ChartDirector.pm	(original)
+++ p5ee/trunk/App-Widget-ChartDirector/lib/App/Widget/ChartDirector.pm	Mon Oct 23 08:32:37 2006
@@ -73,7 +73,12 @@
             $html = $self->write_graph_image($spec);
         };
         if ($@) {
-            $html .= "[Error creating graph image $spec->{image_path}: $@]";
+            if ($@ =~ /(no columns in graph)/) {
+                $html .= "[Error creating graph image, $1.]";
+            }
+            else { 
+                $html .= "[Error creating graph image $spec->{image_path}: $@]";
+            }
         }
     }
     if ($self->{debug}) {
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.