[dw-nonfree] Move cgi-bin/ljhooks.pl to LJ::Hooks module
[commit: http://hg.dwscoalition.org/dw-nonfree/rev/8dab27b47822]
http://bugs.dwscoalition.org/show_bug.cgi?id=2246
Move ljhooks.pl to LJ::Hooks module, update all callers. All hail find+sed.
Patch by
mark.
Files modified:
http://bugs.dwscoalition.org/show_bug.cgi?id=2246
Move ljhooks.pl to LJ::Hooks module, update all callers. All hail find+sed.
Patch by
Files modified:
- cgi-bin/DW/Hooks/EntryForm.pm
- cgi-bin/DW/Hooks/SiteScheme.pm
- cgi-bin/dw-nonfree.pl
--------------------------------------------------------------------------------
diff -r 6df7cf7ff580 -r 8dab27b47822 cgi-bin/DW/Hooks/EntryForm.pm
--- a/cgi-bin/DW/Hooks/EntryForm.pm Wed Dec 23 11:28:25 2009 -0600
+++ b/cgi-bin/DW/Hooks/EntryForm.pm Wed Dec 23 17:32:42 2009 +0000
@@ -15,8 +15,9 @@ package DW::Hooks::EntryForm;
use strict;
use warnings;
+use LJ::Hooks;
-LJ::register_hook( 'entryforminfo', sub {
+LJ::Hooks::register_hook( 'entryforminfo', sub {
my ( $journal, $remote ) = @_;
my $make_list = sub {
diff -r 6df7cf7ff580 -r 8dab27b47822 cgi-bin/DW/Hooks/SiteScheme.pm
--- a/cgi-bin/DW/Hooks/SiteScheme.pm Wed Dec 23 11:28:25 2009 -0600
+++ b/cgi-bin/DW/Hooks/SiteScheme.pm Wed Dec 23 17:32:42 2009 +0000
@@ -14,8 +14,9 @@ package DW::Hooks::SiteScheme;
package DW::Hooks::SiteScheme;
use strict;
+use LJ::Hooks;
-LJ::register_hook('modify_scheme_list', sub {
+LJ::Hooks::register_hook('modify_scheme_list', sub {
my $schemesref = shift;
@$schemesref = (
diff -r 6df7cf7ff580 -r 8dab27b47822 cgi-bin/dw-nonfree.pl
--- a/cgi-bin/dw-nonfree.pl Wed Dec 23 11:28:25 2009 -0600
+++ b/cgi-bin/dw-nonfree.pl Wed Dec 23 17:32:42 2009 +0000
@@ -3,7 +3,7 @@
# THIS IS NOT LICENSED FOR USE.
#
-LJ::register_hook("journal_base", sub {
+LJ::Hooks::register_hook("journal_base", sub {
my ($u, $vhost) = @_;
return undef unless $LJ::ONLY_USER_VHOSTS;
return "#" unless $u;
--------------------------------------------------------------------------------
