mirror of
https://github.com/friendica/friendica
synced 2025-05-14 06:24:10 +02:00
Shorten "Configuration" to "Config" again, since the Wrapper is gone
This commit is contained in:
parent
21640ec5d8
commit
cb80108957
53 changed files with 183 additions and 179 deletions
|
@ -25,7 +25,7 @@ class AutomaticInstallation extends Console
|
|||
private $configCache;
|
||||
|
||||
/**
|
||||
* @var Config\IConfiguration
|
||||
* @var Config\IConfig
|
||||
*/
|
||||
private $config;
|
||||
|
||||
|
@ -89,7 +89,7 @@ Examples
|
|||
HELP;
|
||||
}
|
||||
|
||||
public function __construct(App\Mode $appMode, Config\Cache\ConfigCache $configCache, Config\IConfiguration $config, Database $dba, array $argv = null)
|
||||
public function __construct(App\Mode $appMode, Config\Cache\ConfigCache $configCache, Config\IConfig $config, Database $dba, array $argv = null)
|
||||
{
|
||||
parent::__construct($argv);
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ namespace Friendica\Console;
|
|||
|
||||
use Asika\SimpleConsole\CommandArgsException;
|
||||
use Friendica\App;
|
||||
use Friendica\Core\Config\IConfiguration;
|
||||
use Friendica\Core\Config\IConfig;
|
||||
use RuntimeException;
|
||||
|
||||
/**
|
||||
|
@ -40,7 +40,7 @@ class Config extends \Asika\SimpleConsole\Console
|
|||
*/
|
||||
private $appMode;
|
||||
/**
|
||||
* @var IConfiguration
|
||||
* @var IConfig
|
||||
*/
|
||||
private $config;
|
||||
|
||||
|
@ -78,7 +78,7 @@ HELP;
|
|||
return $help;
|
||||
}
|
||||
|
||||
public function __construct(App\Mode $appMode, IConfiguration $config, array $argv = null)
|
||||
public function __construct(App\Mode $appMode, IConfig $config, array $argv = null)
|
||||
{
|
||||
parent::__construct($argv);
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
namespace Friendica\Console;
|
||||
|
||||
use Friendica\App;
|
||||
use Friendica\Core\Config\IConfiguration;
|
||||
use Friendica\Core\Config\IConfig;
|
||||
|
||||
/**
|
||||
* Sets maintenance mode for this node
|
||||
|
@ -19,7 +19,7 @@ class Maintenance extends \Asika\SimpleConsole\Console
|
|||
*/
|
||||
private $appMode;
|
||||
/**
|
||||
* @var IConfiguration
|
||||
* @var IConfig
|
||||
*/
|
||||
private $config;
|
||||
|
||||
|
@ -52,7 +52,7 @@ HELP;
|
|||
return $help;
|
||||
}
|
||||
|
||||
public function __construct(App\Mode $appMode, IConfiguration $config, $argv = null)
|
||||
public function __construct(App\Mode $appMode, IConfig $config, $argv = null)
|
||||
{
|
||||
parent::__construct($argv);
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
namespace Friendica\Console;
|
||||
|
||||
use Friendica\App;
|
||||
use Friendica\Core\Config\IConfiguration;
|
||||
use Friendica\Core\Config\IConfig;
|
||||
use Friendica\Core\L10n;
|
||||
use Friendica\Core\Update;
|
||||
|
||||
|
@ -24,7 +24,7 @@ class PostUpdate extends \Asika\SimpleConsole\Console
|
|||
*/
|
||||
private $appMode;
|
||||
/**
|
||||
* @var IConfiguration
|
||||
* @var IConfig
|
||||
*/
|
||||
private $config;
|
||||
/**
|
||||
|
@ -46,7 +46,7 @@ HELP;
|
|||
return $help;
|
||||
}
|
||||
|
||||
public function __construct(App\Mode $appMode, IConfiguration $config, L10n $l10n, array $argv = null)
|
||||
public function __construct(App\Mode $appMode, IConfig $config, L10n $l10n, array $argv = null)
|
||||
{
|
||||
parent::__construct($argv);
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ namespace Friendica\Console;
|
|||
use Asika\SimpleConsole\CommandArgsException;
|
||||
use Asika\SimpleConsole\Console;
|
||||
use Console_Table;
|
||||
use Friendica\Core\Config\IConfiguration;
|
||||
use Friendica\Core\Config\IConfig;
|
||||
|
||||
/**
|
||||
* Manage blocked servers
|
||||
|
@ -20,7 +20,7 @@ class ServerBlock extends Console
|
|||
protected $helpOptions = ['h', 'help', '?'];
|
||||
|
||||
/**
|
||||
* @var IConfiguration
|
||||
* @var IConfig
|
||||
*/
|
||||
private $config;
|
||||
|
||||
|
@ -49,7 +49,7 @@ HELP;
|
|||
return $help;
|
||||
}
|
||||
|
||||
public function __construct(IConfiguration $config, $argv = null)
|
||||
public function __construct(IConfig $config, $argv = null)
|
||||
{
|
||||
parent::__construct($argv);
|
||||
|
||||
|
@ -77,9 +77,9 @@ HELP;
|
|||
/**
|
||||
* Prints the whole list of blocked domains including the reason
|
||||
*
|
||||
* @param IConfiguration $config
|
||||
* @param IConfig $config
|
||||
*/
|
||||
private function printBlockedServers(IConfiguration $config)
|
||||
private function printBlockedServers(IConfig $config)
|
||||
{
|
||||
$table = new Console_Table();
|
||||
$table->setHeaders(['Domain', 'Reason']);
|
||||
|
@ -93,11 +93,11 @@ HELP;
|
|||
/**
|
||||
* Adds a server to the blocked list
|
||||
*
|
||||
* @param IConfiguration $config
|
||||
* @param IConfig $config
|
||||
*
|
||||
* @return int The return code (0 = success, 1 = failed)
|
||||
*/
|
||||
private function addBlockedServer(IConfiguration $config)
|
||||
private function addBlockedServer(IConfig $config)
|
||||
{
|
||||
if (count($this->args) < 2 || count($this->args) > 3) {
|
||||
throw new CommandArgsException('Add needs a domain and optional a reason.');
|
||||
|
@ -145,11 +145,11 @@ HELP;
|
|||
/**
|
||||
* Removes a server from the blocked list
|
||||
*
|
||||
* @param IConfiguration $config
|
||||
* @param IConfig $config
|
||||
*
|
||||
* @return int The return code (0 = success, 1 = failed)
|
||||
*/
|
||||
private function removeBlockedServer(IConfiguration $config)
|
||||
private function removeBlockedServer(IConfig $config)
|
||||
{
|
||||
if (count($this->args) !== 2) {
|
||||
throw new CommandArgsException('Remove needs a second parameter.');
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
namespace Friendica\Console;
|
||||
|
||||
use Friendica\Core\Config\IConfiguration;
|
||||
use Friendica\Core\Config\IConfig;
|
||||
|
||||
/**
|
||||
* Tired of chasing typos and finding them after a commit.
|
||||
|
@ -15,7 +15,7 @@ class Typo extends \Asika\SimpleConsole\Console
|
|||
protected $helpOptions = ['h', 'help', '?'];
|
||||
|
||||
/**
|
||||
* @var IConfiguration
|
||||
* @var IConfig
|
||||
*/
|
||||
private $config;
|
||||
|
||||
|
@ -36,7 +36,7 @@ HELP;
|
|||
return $help;
|
||||
}
|
||||
|
||||
public function __construct(IConfiguration $config, array $argv = null)
|
||||
public function __construct(IConfig $config, array $argv = null)
|
||||
{
|
||||
parent::__construct($argv);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue