]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/lockedit.pm
po: inject custom isselflink to fix selflink detection on translation pages
[git.ikiwiki.info.git] / IkiWiki / Plugin / lockedit.pm
index 0fa329251f0b7eb5e6814e50f68d020eaf047eb8..74ddbb1537929189206f675fdb49bfbf9247837c 100644 (file)
@@ -39,8 +39,9 @@ sub canedit ($$) {
                    user => $session->param("name"),
                    ip => $ENV{REMOTE_ADDR},
            )) {
                    user => $session->param("name"),
                    ip => $ENV{REMOTE_ADDR},
            )) {
-               if (! defined $user ||
-                   ! IkiWiki::userinfo_get($session->param("name"), "regdate")) {
+               if ((! defined $user ||
+                   ! IkiWiki::userinfo_get($session->param("name"), "regdate")) &&
+                   exists $IkiWiki::hooks{auth}) {
                        return sub { IkiWiki::needsignin($cgi, $session) };
                }
                else {
                        return sub { IkiWiki::needsignin($cgi, $session) };
                }
                else {