modify
This commit is contained in:
@@ -5,10 +5,10 @@ namespace Console;
|
||||
|
||||
|
||||
use Exception;
|
||||
use Snowflake\Abstracts\Component;
|
||||
use Snowflake\Abstracts\Input;
|
||||
use Snowflake\Event;
|
||||
use Snowflake\Snowflake;
|
||||
use Kiri\Abstracts\Component;
|
||||
use Kiri\Abstracts\Input;
|
||||
use Kiri\Event;
|
||||
use Kiri\Kiri;
|
||||
|
||||
/**
|
||||
* Class AbstractConsole
|
||||
@@ -36,7 +36,7 @@ abstract class AbstractConsole extends Component
|
||||
public function __construct(array $config = [])
|
||||
{
|
||||
$this->_config = $config;
|
||||
$this->signCommand(Snowflake::createObject(DefaultCommand::class));
|
||||
$this->signCommand(Kiri::createObject(DefaultCommand::class));
|
||||
|
||||
parent::__construct($config);
|
||||
}
|
||||
@@ -117,7 +117,7 @@ abstract class AbstractConsole extends Component
|
||||
return;
|
||||
}
|
||||
foreach ($kernel as $command) {
|
||||
$this->signCommand(Snowflake::createObject($command));
|
||||
$this->signCommand(Kiri::createObject($command));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+7
-7
@@ -4,11 +4,11 @@ declare(strict_types=1);
|
||||
namespace Console;
|
||||
|
||||
use ReflectionException;
|
||||
use Snowflake\Abstracts\BaseObject;
|
||||
use Snowflake\Abstracts\TraitApplication;
|
||||
use Snowflake\Exception\ComponentException;
|
||||
use Snowflake\Exception\NotFindClassException;
|
||||
use Snowflake\Snowflake;
|
||||
use Kiri\Abstracts\BaseObject;
|
||||
use Kiri\Abstracts\TraitApplication;
|
||||
use Kiri\Exception\ComponentException;
|
||||
use Kiri\Exception\NotFindClassException;
|
||||
use Kiri\Kiri;
|
||||
|
||||
/**
|
||||
* Class Command
|
||||
@@ -66,7 +66,7 @@ abstract class Command extends BaseObject implements CommandInterface
|
||||
*/
|
||||
private function has($name): bool
|
||||
{
|
||||
return Snowflake::app()->has($name);
|
||||
return Kiri::app()->has($name);
|
||||
}
|
||||
|
||||
|
||||
@@ -79,7 +79,7 @@ abstract class Command extends BaseObject implements CommandInterface
|
||||
*/
|
||||
private function get($name): mixed
|
||||
{
|
||||
return Snowflake::app()->get($name);
|
||||
return Kiri::app()->get($name);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Console;
|
||||
|
||||
use Snowflake\Abstracts\Input;
|
||||
use Kiri\Abstracts\Input;
|
||||
|
||||
/**
|
||||
* Interface CommandInterface
|
||||
|
||||
+2
-2
@@ -4,7 +4,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Console;
|
||||
|
||||
use Snowflake\Snowflake;
|
||||
use Kiri\Kiri;
|
||||
|
||||
/**
|
||||
* Class Console
|
||||
@@ -21,7 +21,7 @@ class Console extends AbstractConsole
|
||||
public function register($class)
|
||||
{
|
||||
if (is_string($class) || is_callable($class, true)) {
|
||||
$class = Snowflake::createObject($class);
|
||||
$class = Kiri::createObject($class);
|
||||
}
|
||||
$this->signCommand($class);
|
||||
}
|
||||
|
||||
@@ -4,8 +4,8 @@ namespace Console;
|
||||
|
||||
|
||||
use Exception;
|
||||
use Snowflake\Abstracts\Providers;
|
||||
use Snowflake\Application;
|
||||
use Kiri\Abstracts\Providers;
|
||||
use Kiri\Application;
|
||||
|
||||
/**
|
||||
* Class ConsoleProviders
|
||||
|
||||
@@ -4,7 +4,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Console;
|
||||
|
||||
use Snowflake\Abstracts\Input;
|
||||
use Kiri\Abstracts\Input;
|
||||
|
||||
/**
|
||||
* Class DefaultCommand
|
||||
|
||||
@@ -4,7 +4,7 @@ declare(strict_types=1);
|
||||
namespace Console;
|
||||
|
||||
|
||||
use Snowflake\Abstracts\Input;
|
||||
use Kiri\Abstracts\Input;
|
||||
|
||||
interface ICommand
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user