summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Scherzinger <info@andy-scherzinger.de>2023-09-07 09:21:57 +0200
committerGitHub <noreply@github.com>2023-09-07 09:21:57 +0200
commitaa8094a71b64f5fbd06328a92df4df8a2228ae3c (patch)
treebb9f3405fb410178401129e728909b066b864b8b
parentbb74c5dfb0d01f49dab4e163d53c89ad583dffc9 (diff)
parent89cca0cd7ce6a9b668e1c901e5704c140c9ee803 (diff)
downloadnextcloud-server-aa8094a71b64f5fbd06328a92df4df8a2228ae3c.tar.gz
nextcloud-server-aa8094a71b64f5fbd06328a92df4df8a2228ae3c.zip
Merge pull request #40315 from nextcloud/backport/40295/stable27
[stable27] Rename AppEcosystemV2 to AppAPI
-rw-r--r--build/stubs/app_api.php (renamed from build/stubs/app_ecosystem_v2.php)4
-rw-r--r--lib/base.php12
-rw-r--r--psalm.xml2
3 files changed, 9 insertions, 9 deletions
diff --git a/build/stubs/app_ecosystem_v2.php b/build/stubs/app_api.php
index d2b07c9c616..1ab63499b77 100644
--- a/build/stubs/app_ecosystem_v2.php
+++ b/build/stubs/app_api.php
@@ -1,10 +1,10 @@
<?php
-namespace OCA\AppEcosystemV2\Service;
+namespace OCA\AppAPI\Service;
use OCP\IRequest;
-class AppEcosystemV2Service {
+class AppAPIService {
/**
* @param IRequest $request
* @param bool $isDav
diff --git a/lib/base.php b/lib/base.php
index e201ca29dcf..d94671327f2 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -1138,7 +1138,7 @@ class OC {
if (OC_User::handleApacheAuth()) {
return true;
}
- if (self::tryAppEcosystemV2Login($request)) {
+ if (self::tryAppAPILogin($request)) {
return true;
}
if ($userSession->tryTokenLogin($request)) {
@@ -1179,17 +1179,17 @@ class OC {
}
}
- protected static function tryAppEcosystemV2Login(OCP\IRequest $request): bool {
+ protected static function tryAppAPILogin(OCP\IRequest $request): bool {
$appManager = Server::get(OCP\App\IAppManager::class);
- if (!$request->getHeader('AE-SIGNATURE')) {
+ if (!$request->getHeader('AUTHORIZATION-APP-API')) {
return false;
}
- if (!$appManager->isInstalled('app_ecosystem_v2')) {
+ if (!$appManager->isInstalled('app_api')) {
return false;
}
try {
- $appEcosystemV2Service = Server::get(OCA\AppEcosystemV2\Service\AppEcosystemV2Service::class);
- return $appEcosystemV2Service->validateExAppRequestToNC($request);
+ $appAPIService = Server::get(OCA\AppAPI\Service\AppAPIService::class);
+ return $appAPIService->validateExAppRequestToNC($request);
} catch (\Psr\Container\NotFoundExceptionInterface|\Psr\Container\ContainerExceptionInterface $e) {
return false;
}
diff --git a/psalm.xml b/psalm.xml
index 52eb9841aec..573879adaa8 100644
--- a/psalm.xml
+++ b/psalm.xml
@@ -81,7 +81,7 @@
<file name="build/stubs/zip.php"/>
<file name="build/stubs/psr_container.php"/>
<file name="3rdparty/sabre/uri/lib/functions.php" />
- <file name="build/stubs/app_ecosystem_v2.php" />
+ <file name="build/stubs/app_api.php" />
</stubs>
<issueHandlers>
<UndefinedClass>