The stock mailarchive_stats.module complains when there are no subscriptions set up:

warning: Invalid argument supplied for foreach() in /Users/sean/svn/mailarchive/mailarchive_stats/mailarchive_stats.module on line 168.

To fix this, $statistics must be declared. Here's a patch:

Index: mailarchive_stats.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/mailarchive/mailarchive_stats/mailarchive_stats.module,v
retrieving revision 1.6
diff -u -r1.6 mailarchive_stats.module
--- mailarchive_stats.module	16 Nov 2007 02:36:36 -0000	1.6
+++ mailarchive_stats.module	10 Dec 2007 02:24:45 -0000
@@ -119,6 +119,7 @@
   $hour = date('YmdH', $now);
   $lasthour = date('YmdH', $now - 3600);
 
+  $statistics = array();
   $result = db_query('SELECT sid, nid, urlname, subscription_status, message_count, last_message FROM {mailarchive_subscriptions}');
   while ($subscription = db_fetch_object($result)) {
     // All time statistics.

Comments

jeremy’s picture

Status: Needs review » Fixed

Thanks for the bug report. Fix committed. I added a friendly message if no subscriptions are created.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.