Re: Small patch for no_old_comments.py plugin

Ryan Barrett <pyblosxom-6sb6M7qyT/[email protected]>
Newsgroups gmane.comp.web.pyblosxom.devel
Message-ID <[email protected]>
On Wed, 22 Nov 2006, Martn van de Streek wrote:

> I've made a small patch for no_old_comments.py, to make the maximum age of a
> post configurable (using the 'no_old_comments_max_age' config option). It
> also sanitizes logging to using Logger.

thanks! that's a great idea. it doesn't look like this patch works, though. 
the max age is still hard-coded. from your patch:

>      if ( (time.time() - entry['mtime']) >= 2419200):
> -        print >> sys.stderr, "Too old!"
> +        logger.info('Entry too old, comment not posted!')

it looks like 2419200 should be replaced with max_age. let me know if you 
agree, and i'll make the change and apply the patch.

-Ryan

--
http://snarfed.org/

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.