mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-29 09:43:16 +00:00
Allow forceHttps to be disabled, fixes #3710
This commit is contained in:
parent
f776c79284
commit
a31bdec750
2 changed files with 3 additions and 1 deletions
|
@ -40,9 +40,10 @@ class AppServiceProvider extends ServiceProvider
|
||||||
*/
|
*/
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
if (preg_match("/^https/", env('APP_URL')) || env('APP_ENV') === 'production') {
|
if(config('instance.force_https_urls')) {
|
||||||
URL::forceScheme('https');
|
URL::forceScheme('https');
|
||||||
}
|
}
|
||||||
|
|
||||||
Schema::defaultStringLength(191);
|
Schema::defaultStringLength(191);
|
||||||
Paginator::useBootstrap();
|
Paginator::useBootstrap();
|
||||||
Avatar::observe(AvatarObserver::class);
|
Avatar::observe(AvatarObserver::class);
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
return [
|
return [
|
||||||
|
'force_https_urls' => env('FORCE_HTTPS_URLS', true),
|
||||||
|
|
||||||
'description' => env('INSTANCE_DESCRIPTION', 'Pixelfed - Photo sharing for everyone'),
|
'description' => env('INSTANCE_DESCRIPTION', 'Pixelfed - Photo sharing for everyone'),
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue