Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/updater.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCôme Chilliet <come.chilliet@nextcloud.com>2022-08-25 11:40:56 +0300
committerCôme Chilliet <come.chilliet@nextcloud.com>2022-08-25 11:40:56 +0300
commitf039ecf6f1ce3e5154f62ff823f9a81c89829b57 (patch)
tree755a107a5a56fcc67e5d201bd0641c19bd356cbe
parent5c22c17f842ab42b246e666ac22dcf1685943143 (diff)
Update index.php from lib/
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
-rw-r--r--index.php11
1 files changed, 4 insertions, 7 deletions
diff --git a/index.php b/index.php
index 68e0b78..4c4acef 100644
--- a/index.php
+++ b/index.php
@@ -151,11 +151,9 @@ class Updater {
/**
* Returns currently used release channel
- *
- * @return string
*/
- private function getCurrentReleaseChannel() {
- return !is_null($this->getConfigOption('updater.release.channel')) ? $this->getConfigOption('updater.release.channel') : 'stable';
+ private function getCurrentReleaseChannel(): string {
+ return (string)($this->getConfigOption('updater.release.channel') ?? 'stable');
}
/**
@@ -206,10 +204,9 @@ class Updater {
/**
* Returns the specified config options
*
- * @param string $key
* @return mixed|null Null if the entry is not found
*/
- public function getConfigOption($key) {
+ public function getConfigOption(string $key) {
return isset($this->configValues[$key]) ? $this->configValues[$key] : null;
}
@@ -1078,7 +1075,7 @@ EOF;
}
/**
- * @return string
+ * @return array
* @throws \Exception
*/
public function currentStep() {