diff options
author | Vitor Mattos <vitor@php.rio> | 2021-11-27 16:28:17 +0300 |
---|---|---|
committer | Vitor Mattos <vitor@php.rio> | 2021-11-27 16:31:29 +0300 |
commit | 213c4806ab69837b2bc4801029bd00e43a710d01 (patch) | |
tree | 1715566dc5b89deef45174e9456f69851c78204c /lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php | |
parent | 93ea4ace8e29d154f98365a84371abe93f239fe7 (diff) |
Remove deprecated appinfo/app.php and replace APP_NAME by APP_ID
Signed-off-by: Vitor Mattos <vitor@php.rio>
Diffstat (limited to 'lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php')
-rw-r--r-- | lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php b/lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php index 09d6b30..2133a6f 100644 --- a/lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php +++ b/lib/Service/Gateway/SMS/Provider/PuzzelSMSConfig.php @@ -44,7 +44,7 @@ class PuzzelSMSConfig implements IProviderConfig { } private function getOrFail(string $key): string { - $val = $this->config->getAppValue(Application::APP_NAME, $key, null); + $val = $this->config->getAppValue(Application::APP_ID, $key, null); if (is_null($val)) { throw new ConfigurationException(); } @@ -56,7 +56,7 @@ class PuzzelSMSConfig implements IProviderConfig { } public function setUrl(string $url) { - $this->config->setAppValue(Application::APP_NAME, 'puzzel_url', $url); + $this->config->setAppValue(Application::APP_ID, 'puzzel_url', $url); } public function getUser(): string { @@ -64,7 +64,7 @@ class PuzzelSMSConfig implements IProviderConfig { } public function setUser(string $user) { - $this->config->setAppValue(Application::APP_NAME, 'puzzel_user', $user); + $this->config->setAppValue(Application::APP_ID, 'puzzel_user', $user); } public function getPassword(): string { @@ -72,7 +72,7 @@ class PuzzelSMSConfig implements IProviderConfig { } public function setPassword(string $password) { - $this->config->setAppValue(Application::APP_NAME, 'puzzel_password', $password); + $this->config->setAppValue(Application::APP_ID, 'puzzel_password', $password); } public function getServiceId() { @@ -80,17 +80,17 @@ class PuzzelSMSConfig implements IProviderConfig { } public function setServiceId(string $serviceid) { - $this->config->setAppValue(Application::APP_NAME, 'puzzel_serviceid', $serviceid); + $this->config->setAppValue(Application::APP_ID, 'puzzel_serviceid', $serviceid); } public function isComplete(): bool { - $set = $this->config->getAppKeys(Application::APP_NAME); + $set = $this->config->getAppKeys(Application::APP_ID); return count(array_intersect($set, self::expected)) === count(self::expected); } public function remove() { foreach (self::expected as $key) { - $this->config->deleteAppValue(Application::APP_NAME, $key); + $this->config->deleteAppValue(Application::APP_ID, $key); } } } |