Created Codestriker topic at:
http://codestriker.sourceforge.net/cgi-bin/codestriker.pl?topic=4418712&action=view
User: sits
Date: 05/02/14 02:14:20
Modified: bin codestriker.pl.base
Log:
Automatically handle older config files which still use $allow_comment_email
instead of the new $email_send_options configuration.
Index: codestriker.pl.base
===================================================================
RCS file: /cvsroot/codestriker/codestriker/bin/codestriker.pl.base,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- codestriker.pl.base 30 Jan 2005 02:35:50 -0000 1.17
+++ codestriker.pl.base 14 Feb 2005 10:14:19 -0000 1.18
@@ -61,6 +61,7 @@
use Codestriker::Template::Plugin::AutomagicLinks;
use Codestriker::Template::Plugin::JavascriptEscape;
+use Codestriker::Template::Plugin::StringObfuscator;
# Set the temp file location, if one has been specified.
if (defined $Codestriker::tmpdir && $Codestriker::tmpdir ne '') {
@@ -102,6 +103,19 @@
push @Codestriker::topic_states, 'Deleted';
}
+ # Check if the old $allow_comment_email configuration option has been
+ # specified in the config file, rather than the new $email_send_options
+ # setting.
+ if (defined $Codestriker::allow_comment_email &&
+ ! defined $Codestriker::email_send_options) {
+ $Codestriker::email_send_options =
+ {
+ comments_sent_to_topic_author => $Codestriker::allow_comment_email,
+ comments_sent_to_commenter => $Codestriker::allow_comment_email,
+ topic_state_change_sent_to_reviewers => 0
+ };
+ }
+
# Limit the size of the posts that can be done.
$CGI::POST_MAX=$Codestriker::DIFF_SIZE_LIMIT;
|