[development] Adding db_rewrite_sql to comment.module

Josh Koenig josh at chapterthreellc.com
Sun May 27 19:37:41 UTC 2007

Shameless patch-whoring alert!

I've been working on a number of projects lately that involve fine- 
tuning access, and since I got to experience Andy Kirkham's lesson on  
hook_db_rewrite_sql, I've been loving the power of this system to  
handle node access.

However, in contrast to what the hook documentation says ("For  
comments, it is cid"), comment.module doesn't contain the critical  
call to db_rewrite_sql in comment_render(). This patch fixes that:


I've tested this pretty extensively on 5.1, and re-rolled without  
errors for 6-dev. My primary application for this is an ad-hoc  
private comment system called whisper.module which I'll be releasing  
in the next month.


Josh Koenig, Partner
josh at chapterthreellc.com
AIM: chap3josh

More information about the development mailing list