From 53cabc0171f6628f428fbc02a6ae48dcab5e4c6d Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Sun, 4 Jan 2009 23:56:03 -0500 Subject: trac750 added some output to the facebook_update.php script darcs-hash:20090105045603-7b5ce-2cef1b92d9c91b0db70269d94f42ae06076229b2.gz --- _darcs/pristine/scripts/update_facebook.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to '_darcs/pristine/scripts') diff --git a/_darcs/pristine/scripts/update_facebook.php b/_darcs/pristine/scripts/update_facebook.php index 02e47cefe..15c0e49f8 100644 --- a/_darcs/pristine/scripts/update_facebook.php +++ b/_darcs/pristine/scripts/update_facebook.php @@ -48,6 +48,10 @@ $current_time = time(); $notice = get_facebook_notices(get_last_updated()); +print date('r', $current_time) . " Looking for notices to send to Facebook...\n"; + +$cnt = 0; + while($notice->fetch()) { $flink = Foreign_link::getByUserID($notice->profile_id, 2); @@ -60,12 +64,15 @@ while($notice->fetch()) { if (!preg_match('/@[a-zA-Z0-9_]{1,15}\b/u', $content) || (($flink->noticesync & FOREIGN_NOTICE_SEND_REPLY) == FOREIGN_NOTICE_SEND_REPLY)) { update_status($fbuid, $content); + $cnt++; } } } update_last_updated($current_time); +print "Sent $cnt notices to Facebook.\n"; + exit(0); -- cgit v1.2.3-54-g00ecf