Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] [PATCH] filter-person hook
@ 2008-06-17 19:02 Ben Walton
  2008-06-19 17:46 ` William Morgan
  0 siblings, 1 reply; 2+ messages in thread
From: Ben Walton @ 2008-06-17 19:02 UTC (permalink / raw)


Hi All,

After being a little frustrated with the PersonManager machinery and
what it did to mail from our ticketing system, I decided to go in a
rip out that code (as William mentioned might be worthwhile some time
back).  I did this but wasn't thrilled with the result...all threads
in the index are initially displayed without the 'proper' names on
them.  In most cases, the PersonManager code was doing the right thing
(at least in my view) and I like the functionality overall.

In light of this I decided to add a hook instead that lets the user
determine on the fly whether or not to cache display names in the
PersonManager.  The attached patch adds the filter-person hook to
accomplish this.  The hook is passed a person object and should return
a boolean value.  A true value indicates that the person object for
the specific piece of mail should be returned, thus giving sup the
name attached to the individual piece of mail.  False indicates that
the 'best' name as cached by PersonManager will be used.  I've been
running this patch for about a week and am happy with it.  A colleague
has also been using it.

I hope you'll find it useful as well.  I think it's a "best of both
worlds" type approach!

-Ben
-- 
---------------------------------------------------------------------------------------------------------------------------
Ben Walton <bdwalton at gmail.com>

When one person suffers from a delusion, it is called insanity. When
many people suffer from a delusion it is called Religion.
Robert M. Pirsig, Zen and the Art of Motorcycle Maintenance

---------------------------------------------------------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Added-filter-person-hook.patch
Type: text/x-diff
Size: 2560 bytes
Desc: not available
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20080617/e858d40f/attachment.bin>


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [sup-talk] [PATCH] filter-person hook
  2008-06-17 19:02 [sup-talk] [PATCH] filter-person hook Ben Walton
@ 2008-06-19 17:46 ` William Morgan
  0 siblings, 0 replies; 2+ messages in thread
From: William Morgan @ 2008-06-19 17:46 UTC (permalink / raw)


Reformatted excerpts from Ben Walton's message of 2008-06-17:
> I hope you'll find it useful as well.  I think it's a "best of both
> worlds" type approach!

Sounds like a good compromise. I'll take a look at it.
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-06-19 17:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-06-17 19:02 [sup-talk] [PATCH] filter-person hook Ben Walton
2008-06-19 17:46 ` William Morgan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox