mirror of
https://github.com/bs-community/blessing-skin-server.git
synced 2025-02-23 14:59:07 +08:00
Refactor
This commit is contained in:
parent
3f42d9dfc9
commit
fab3da8f7f
@ -5,7 +5,7 @@ namespace App\Console\Commands;
|
||||
use App\Models\User;
|
||||
use Illuminate\Console\Command;
|
||||
|
||||
class ExecuteInstallation extends Command
|
||||
class BsInstallCommand extends Command
|
||||
{
|
||||
protected $signature = 'bs:install {email} {password} {nickname}';
|
||||
|
||||
@ -27,11 +27,7 @@ class ExecuteInstallation extends Command
|
||||
$this->call('jwt:secret', ['--no-interaction' => true]);
|
||||
$this->call('passport:keys', ['--no-interaction' => true]);
|
||||
|
||||
$siteUrl = url('/');
|
||||
if (ends_with($siteUrl, '/index.php')) {
|
||||
$siteUrl = substr($siteUrl, 0, -10);
|
||||
}
|
||||
option(['site_url' => $siteUrl]);
|
||||
option(['site_url' => url('/')]);
|
||||
|
||||
$admin = new User;
|
||||
$admin->email = $this->argument('email');
|
@ -5,7 +5,7 @@ namespace App\Console\Commands;
|
||||
use App\Services\PluginManager;
|
||||
use Illuminate\Console\Command;
|
||||
|
||||
class DisablePlugin extends Command
|
||||
class PluginDisableCommand extends Command
|
||||
{
|
||||
/**
|
||||
* The name and signature of the console command.
|
@ -5,7 +5,7 @@ namespace App\Console\Commands;
|
||||
use App\Services\PluginManager;
|
||||
use Illuminate\Console\Command;
|
||||
|
||||
class EnablePlugin extends Command
|
||||
class PluginEnableCommand extends Command
|
||||
{
|
||||
/**
|
||||
* The name and signature of the console command.
|
@ -17,9 +17,9 @@ class Kernel extends ConsoleKernel
|
||||
Commands\SaltRandomCommand::class,
|
||||
Commands\MigratePlayersTable::class,
|
||||
Commands\MigrateCloset::class,
|
||||
Commands\ExecuteInstallation::class,
|
||||
Commands\BsInstallCommand::class,
|
||||
Commands\RegressLikesField::class,
|
||||
Commands\EnablePlugin::class,
|
||||
Commands\DisablePlugin::class,
|
||||
Commands\PluginEnableCommand::class,
|
||||
Commands\PluginDisableCommand::class,
|
||||
];
|
||||
}
|
||||
|
@ -4,7 +4,7 @@ namespace Tests;
|
||||
|
||||
use App\Services\PluginManager;
|
||||
|
||||
class DisablePluginTest extends TestCase
|
||||
class PluginDisableCommandTest extends TestCase
|
||||
{
|
||||
public function testDisablePlugin()
|
||||
{
|
@ -4,7 +4,7 @@ namespace Tests;
|
||||
|
||||
use App\Services\PluginManager;
|
||||
|
||||
class EnablePluginTest extends TestCase
|
||||
class PluginEnableCommandTest extends TestCase
|
||||
{
|
||||
public function testEnablePlugin()
|
||||
{
|
Loading…
Reference in New Issue
Block a user