[PATCH] register_hook_before to complement register_hook

Martin Atkins mart at degeneration.co.uk
Sun Feb 3 12:18:29 UTC 2008

Jacob Burkhart wrote:
> Hi,
> I have a need in my plugin for an additional method on VHost.pm called 
> register_hook_before
> This is because I want my offline storage plugin to be registered last 
> in the chain for message delivery, but First in the chain for 
> OnInitialPresence

While I understand why you'd want to do this, I'm concerned that it will 
make the plugin mechanism more confusing for users if plugins are able 
to "jump the queue" and insert themselves at the start of the list.

Right now the rule is that plugins defined earlier in the configuration 
file run first. This is quite easy to understand.

Can you just break your plugin into two pieces and have one at the start 
and one at the end? What does your plugin do?


More information about the Djabberd mailing list