aboutsummaryrefslogtreecommitdiffstats
path: root/pullimap
diff options
context:
space:
mode:
Diffstat (limited to 'pullimap')
-rwxr-xr-xpullimap3
1 files changed, 1 insertions, 2 deletions
diff --git a/pullimap b/pullimap
index 8eb2ac0..3eb2b52 100755
--- a/pullimap
+++ b/pullimap
@@ -346,7 +346,6 @@ unless (defined $CONFIG{idle}) {
$CONFIG{idle} = 1740 if defined $CONFIG{idle} and $CONFIG{idle} == 0; # 29 mins
while(1) {
- my $r = $IMAP->idle($CONFIG{idle}, sub() { $IMAP->has_new_mails($MAILBOX) });
- pull() if $r;
+ pull() if $IMAP->idle($CONFIG{idle}, \&Net::IMAP::InterIMAP::has_new_mails);
purge();
}