Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove terms checkbox for self hosted #32

Merged
merged 2 commits into from
Nov 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
APP_NAME=Investbrain
APP_ENV=production
APP_KEY=
APP_DEBUG=false
APP_DEBUG=true
APP_TIMEZONE=UTC
APP_PORT=8000
APP_URL="http://localhost:${APP_PORT}"
Expand Down
10 changes: 10 additions & 0 deletions app/Providers/JetstreamServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

namespace App\Providers;

use Illuminate\Support\Arr;
use Laravel\Jetstream\Features;
use App\Actions\Jetstream\DeleteUser;
use Illuminate\Support\Facades\Config;
use Illuminate\Support\ServiceProvider;
use Laravel\Jetstream\Jetstream;

Expand All @@ -26,6 +29,13 @@ public function boot(): void

Jetstream::deleteUsersUsing(DeleteUser::class);

if ( config('investbrain.self_hosted', false) ) {

Config::set(
'jetstream.features',
array_keys(Arr::except(array_values(config('jetstream.features')), Features::termsAndPrivacyPolicy()))
);
}
}

/**
Expand Down