Skip to content

Commit

Permalink
Merge pull request #783 from nextcloud/dependabot/composer/vendor-bin…
Browse files Browse the repository at this point in the history
…/csfixer/nextcloud/coding-standard-1.3.1
  • Loading branch information
provokateurin authored Sep 21, 2024
2 parents 62602ca + 860d43f commit 636790f
Show file tree
Hide file tree
Showing 7 changed files with 56 additions and 2,574 deletions.
2 changes: 1 addition & 1 deletion .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

require_once './vendor/autoload.php';
require_once './vendor-bin/csfixer/vendor/autoload.php';

use Nextcloud\CodingStandard\Config;

Expand Down
6 changes: 3 additions & 3 deletions lib/Controller/APIController.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public function get(): DataResponse {
$site['icon'] = $this->url->linkToRouteAbsolute('external.icon.showIcon', ['icon' => 'external.svg']);
}

$site['redirect'] = (int) $site['redirect'];
$site['redirect'] = (int)$site['redirect'];

unset($site['lang'], $site['device'], $site['groups']);
$sites[] = $site;
Expand Down Expand Up @@ -131,7 +131,7 @@ public function getAdmin(): DataResponse {
*/
public function add(string $name, string $url, string $lang, string $type, string $device, string $icon, array $groups, int $redirect): DataResponse {
try {
return new DataResponse($this->sitesManager->addSite($name, $url, $lang, $type, $device, $icon, $groups, (bool) $redirect));
return new DataResponse($this->sitesManager->addSite($name, $url, $lang, $type, $device, $icon, $groups, (bool)$redirect));
} catch (InvalidNameException $e) {
return new DataResponse(['error' => $this->l->t('The given label is invalid'), 'field' => 'name'], Http::STATUS_BAD_REQUEST);
} catch (InvalidURLException $e) {
Expand All @@ -154,7 +154,7 @@ public function add(string $name, string $url, string $lang, string $type, strin
*/
public function update(int $id, string $name, string $url, string $lang, string $type, string $device, string $icon, array $groups, int $redirect): DataResponse {
try {
return new DataResponse($this->sitesManager->updateSite($id, $name, $url, $lang, $type, $device, $icon, $groups, (bool) $redirect));
return new DataResponse($this->sitesManager->updateSite($id, $name, $url, $lang, $type, $device, $icon, $groups, (bool)$redirect));
} catch (SiteNotFoundException $e) {
return new DataResponse(['error' => $this->l->t('The site does not exist'), 'field' => 'site'], Http::STATUS_NOT_FOUND);
} catch (InvalidNameException $e) {
Expand Down
2 changes: 1 addition & 1 deletion lib/Controller/IconController.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public function __construct(
IL10N $l,
IAppData $appData,
IAppManager $appManager,
ITimeFactory $timeFactory
ITimeFactory $timeFactory,
) {
parent::__construct($appName, $request);

Expand Down
4 changes: 2 additions & 2 deletions lib/Settings/Admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ public function getSection() {

/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
Expand Down
4 changes: 2 additions & 2 deletions lib/Settings/Personal.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ public function getSection() {

/**
* @return int whether the form should be rather on the top or bottom of
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
* the admin section. The forms are arranged in ascending order of the
* priority values. It is required to return a value between 0 and 100.
*
* E.g.: 70
*/
Expand Down
2 changes: 1 addition & 1 deletion lib/SitesManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ public function getSitesToDisplay() {

$site['url'] = str_replace(
['{email}', '{uid}', '{displayname}', '{jwt}', '{groups}'],
array_map('rawurlencode', [$email, $uid, $displayName, $jwt, implode(",", $groups)]),
array_map('rawurlencode', [$email, $uid, $displayName, $jwt, implode(',', $groups)]),
$site['url']
);

Expand Down
Loading

0 comments on commit 636790f

Please sign in to comment.