Skip to content

Commit

Permalink
AntiSpam: Start checking spam immediately on start
Browse files Browse the repository at this point in the history
  • Loading branch information
CyberShadow committed Sep 15, 2012
1 parent 35a657d commit f73da7c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions AntiSpam.d
Expand Up @@ -210,7 +210,8 @@ void main(string[] args)
string[] enabledEngines = splitLines(readText("data/engines.txt"));
bool[string] knownPosts;

setInterval({
void run()
{
string[] posts = getPostsToModerate() ~ getThreadsToModerate();
foreach (id; posts)
if (!(id in knownPosts))
Expand Down Expand Up @@ -263,7 +264,10 @@ void main(string[] args)
log("###########################################################################################");
knownPosts[id] = true;
}
}, TickDuration.from!"seconds"(30));// +/
}

run();
setInterval(&run, TickDuration.from!"seconds"(30));// +/

new AntiSpamFrontend();
socketManager.loop();
Expand Down

0 comments on commit f73da7c

Please sign in to comment.