• Do not register here on develop.twiki.org, login with your twiki.org account.
• Use View topic Item7700 for generic doc work for TWiki-6.0.2. Use View topic Item7703 for doc work on extensions that are not part of a release. More... Close
• Anything you create or change in standard webs (Main, TWiki, Sandbox etc) will be automatically reverted on every SVN update.
Does this site look broken?. Use the LitterTray web for test cases.

... although it is used mostly on the command line or from within a cron job.

Fixed in SVN 8808.

MD

Patch from change log:

--- twiki/lib/TWiki/Contrib/Mailer.pm   2006-02-15 17:27:43 UTC (rev 8807)
+++ twiki/lib/TWiki/Contrib/Mailer.pm   2006-02-15 17:32:46 UTC (rev 8808)
@@ -77,7 +77,10 @@
     $webstr = '*' unless ( $webstr );
     $webstr =~ s/\*/\.\*/g;
 
-    $twiki ||= new TWiki( $TWiki::cfg{DefaultUserLogin} );
+    if (!defined $twiki) {
+      $twiki = new TWiki( $TWiki::cfg{DefaultUserLogin} );
+      $twiki->enterContext( 'command_line' );
+    }
 
     # absolute URL context for email generation
     $twiki->enterContext( 'absolute_urls' );

Modified: twiki/branches/DEVELOP/twikiplugins/MailerContrib/tools/mailnotify
===================================================================
--- twiki/tools/mailnotify   2006-02-15 17:27:43 UTC (rev 8807)
+++ twiki/tools/mailnotify   2006-02-15 17:32:46 UTC (rev 8808)
@@ -33,7 +33,7 @@
 my @webs = ();
 
 # Called from the command line
-foreach $arg ( @ARGV ) {
+foreach my $arg ( @ARGV ) {
     if ( $arg eq "-q" ) {
         $verbose = 0;
     } else {

-- PTh

Closed with the release of 4.0.2

KJL

ItemTemplate
Summary mailnotify does not enter the command_line context
ReportedBy TWiki:Main.MichaelDaum
Codebase

SVN Range Tue, 14 Feb 2006 build 8800
AppliesTo Extension
Component MailerContrib
Priority Normal
CurrentState Closed
WaitingFor

Checkins 8808
TargetRelease patch
Edit | Attach | Watch | Print version | History: r7 < r6 < r5 < r4 < r3 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r7 - 2006-04-01 - KennethLavrsen
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback