Show correct error message when running CLI scripts.
authorJan Schneider <jan@horde.org>
Thu, 20 Jan 2011 18:32:16 +0000 (19:32 +0100)
committerJan Schneider <jan@horde.org>
Thu, 20 Jan 2011 18:32:16 +0000 (19:32 +0100)
framework/Core/lib/Horde/Registry.php

index 8a9fc55..23b71c0 100644 (file)
@@ -1775,7 +1775,7 @@ class Horde_Registry
     {
         if (Horde_Cli::runningFromCLI()) {
             $cli = new Horde_Cli();
-            $cli->fatal(Horde_Core_Translation::t("You are not authenticated."));
+            $cli->fatal($e ? $e : Horde_Core_Translation::t("You are not authenticated."));
         }
 
         if (is_null($e)) {