Skip to content

Commit

Permalink
Merge pull request #10283 from snipe/fixes/remove_get_logout_route
Browse files Browse the repository at this point in the history
  • Loading branch information
snipe committed Nov 8, 2021
2 parents fba0e2b + 38c36af commit 16d18bc
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
19 changes: 13 additions & 6 deletions resources/views/layouts/default.blade.php
Expand Up @@ -354,10 +354,17 @@
@endcan
<li class="divider"></li>
<li>
<a href="{{ url('/logout') }}">
<i class="fa fa-sign-out fa-fw" aria-hidden="true"></i>
{{ trans('general.logout') }}
</a>

<a href="{{ route('logout') }}" onclick="event.preventDefault(); document.getElementById('logout-form').submit();">
<i class="fa fa-sign-out fa-fw"></i> {{ trans('general.logout') }}
{{ csrf_field() }}
</a>

<form id="logout-form" action="{{ route('logout') }}" method="POST" style="display: none;">
{{ csrf_field() }}
</form>


</li>
</ul>
</li>
Expand Down Expand Up @@ -832,7 +839,7 @@

<!-- end main container -->

<div class="modal modal-danger fade" id="dataConfirmModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal modal-danger fade" id="dataConfirmModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
Expand All @@ -845,7 +852,7 @@
{{ csrf_field() }}
{{ method_field('DELETE') }}

<button type="button" class="btn btn-default pull-left" data-dismiss="modal">{{ trans('general.cancel') }}</button>
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">{{ trans('general.cancel') }}</button>
<button type="submit" class="btn btn-outline" id="dataConfirmOK">{{ trans('general.yes') }}</button>
</form>
</div>
Expand Down
6 changes: 0 additions & 6 deletions routes/web.php
Expand Up @@ -463,12 +463,6 @@
'uses' => 'Auth\LoginController@login' ]
);

Route::get(
'logout',
[
'as' => 'logout',
'uses' => 'Auth\LoginController@logout' ]
);

});

Expand Down

0 comments on commit 16d18bc

Please sign in to comment.