Mercurial > libervia-web
comparison libervia.py @ 64:104e71ce2293
browser side: fixed microblog filtering
author | Goffi <goffi@goffi.org> |
---|---|
date | Thu, 02 Jun 2011 15:57:57 +0200 |
parents | 12e889a683ce |
children | 9d8e79ac4c9c |
comparison
equal
deleted
inserted
replaced
63:dc88ff7a030d | 64:104e71ce2293 |
---|---|
247 """Check if an entry can go in MicroblogPanel and add to it | 247 """Check if an entry can go in MicroblogPanel and add to it |
248 @param mblog_panel: MicroblogPanel instance | 248 @param mblog_panel: MicroblogPanel instance |
249 @param sender: jid of the entry sender | 249 @param sender: jid of the entry sender |
250 @param _groups: groups which can receive this entry | 250 @param _groups: groups which can receive this entry |
251 @param mblog_entry: MicroblogEntry instance""" | 251 @param mblog_entry: MicroblogEntry instance""" |
252 if mblog_panel.isJidAccepted(sender) or _groups == None or _groups.intersection(mblog_panel.accepted_groups): | 252 if mblog_panel.isJidAccepted(sender) or (_groups == None and self.whoami and sender == self.whoami.bare) \ |
253 or (_groups and _groups.intersection(mblog_panel.accepted_groups)): | |
253 mblog_panel.addEntry(mblog_entry) | 254 mblog_panel.addEntry(mblog_entry) |
254 | 255 |
255 def FillMicroblogPanel(self, mblog_entry): | 256 def FillMicroblogPanel(self, mblog_entry): |
256 """Fill a microblog panel with entries in cache | 257 """Fill a microblog panel with entries in cache |
257 @param mblog_panel: MicroblogPanel instance | 258 @param mblog_panel: MicroblogPanel instance |