File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,8 @@ sub login :Local :Args(0) :ActionClass('REST') { }
2525sub login_POST {
2626 my ($self , $c ) = @_ ;
2727
28+ badRequest($c , " Local authentication is disabled." ) if $c -> config-> {disable_local_auth };
29+
2830 my $username = $c -> stash-> {params }-> {username } // " " ;
2931 my $password = $c -> stash-> {params }-> {password } // " " ;
3032
Original file line number Diff line number Diff line change 146146 <a class="dropdown-item" href="/github-redirect?after=[% c.req.path | uri %]">Sign in with GitHub</a>
147147 <div class="dropdown-divider"></div>
148148 [% END %]
149- <a class="dropdown-item" href="#hydra-signin" data-toggle="modal">Sign in with a Hydra account</a>
149+ [% UNLESS c.config.disable_local_auth %]
150+ <a class="dropdown-item" href="#hydra-signin" data-toggle="modal">Sign in with a Hydra account</a>
151+ [% END %]
150152 [% END %]
151153 [% END %]
152154
You can’t perform that action at this time.
0 commit comments