Dan Brown

Prevented custom HTML being inserted on settings page

Gives option for fixing if badly formatted HTML is inserted.
Closes #310
...@@ -23,9 +23,10 @@ ...@@ -23,9 +23,10 @@
23 23
24 @include('partials/custom-styles') 24 @include('partials/custom-styles')
25 25
26 + @if(setting('app-custom-head') && \Route::currentRouteName() !== 'settings')
26 <!-- Custom user content --> 27 <!-- Custom user content -->
27 - @if(setting('app-custom-head'))
28 {!! setting('app-custom-head') !!} 28 {!! setting('app-custom-head') !!}
29 + <!-- End custom user content -->
29 @endif 30 @endif
30 </head> 31 </head>
31 <body class="@yield('body-class')" ng-app="bookStack"> 32 <body class="@yield('body-class')" ng-app="bookStack">
......
...@@ -129,7 +129,7 @@ Route::group(['middleware' => 'auth'], function () { ...@@ -129,7 +129,7 @@ Route::group(['middleware' => 'auth'], function () {
129 129
130 // Settings 130 // Settings
131 Route::group(['prefix' => 'settings'], function() { 131 Route::group(['prefix' => 'settings'], function() {
132 - Route::get('/', 'SettingController@index'); 132 + Route::get('/', 'SettingController@index')->name('settings');
133 Route::post('/', 'SettingController@update'); 133 Route::post('/', 'SettingController@update');
134 134
135 // Users 135 // Users
......