----- Original Message -----
> From: Alexis Sukrieh <[email protected]>
> I'll do it that way:
>
> In the plugin:
>
> register 'before_hook_for_prefix' => sub {
> my ($prefix) = @_;
>
> hook 'before' => sub {
> if (request->path =~ /^$prefix/) {
> ....
> }
> };
> };
>
> And in the app:
>
> use MyPlugin;
>
> before_hook_for_prefix '/companies';
>
> See the idea?
>
> Of course, that's one way, there must be many others.
Works like a charm and tests pass with flying colors. Thanks!
Cheers,
Ovid
--
Live and work overseas - http://overseas-exile.blogspot.com/
Buy the book - http://www.oreilly.com/catalog/perlhks/
Tech blog - http://blogs.perl.org/users/ovid/
Twitter - http://twitter.com/OvidPerl/
_______________________________________________
Dancer-users mailing list
[email protected]
http://www.backup-manager.org/cgi-bin/listinfo/dancer-users