From e543c294e1dad7d18e75e80f131f07d127acd950 Mon Sep 17 00:00:00 2001 From: dms Date: Sat, 7 Apr 2001 12:07:06 +0000 Subject: [PATCH] - load file if we enabled option on the fly before re-run. git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk@433 c11ca15a-4712-0410-83d8-924469b57eb5 --- blootbot/src/Modules/News.pl | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/blootbot/src/Modules/News.pl b/blootbot/src/Modules/News.pl index b93788d..b2f8b11 100644 --- a/blootbot/src/Modules/News.pl +++ b/blootbot/src/Modules/News.pl @@ -21,6 +21,15 @@ sub Parse { my($what) = @_; $chan = undef; + if (!keys %::news) { + if (!exists $cache{newsFirst}) { + &::DEBUG("looks like we enabled news option just then; loading up news file just in case."); + $cache{newsFirst} = 1; + } + + &readNews(); + } + if ($::msgType eq "private") { } else { $chan = $::chan; -- 2.39.5