From 99721caef10711e63c53f235815edcc0dee77caa Mon Sep 17 00:00:00 2001 From: Andreas Hennings Date: Thu, 7 Nov 2024 23:04:48 +0100 Subject: [PATCH] Issue #43: Add public access modifier. --- src/Controller/WopiController.php | 6 +++--- src/Cool/CoolUtils.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Controller/WopiController.php b/src/Controller/WopiController.php index 4fc5f0cc..4f22dd4a 100644 --- a/src/Controller/WopiController.php +++ b/src/Controller/WopiController.php @@ -51,7 +51,7 @@ public static function permissionDenied(): Response { * @return \Symfony\Component\HttpFoundation\Response * The response with file contents. */ - function wopiCheckFileInfo(string $id, Request $request) { + public function wopiCheckFileInfo(string $id, Request $request) { $token = $request->query->get('access_token'); $jwt_payload = CoolUtils::verifyTokenForId($token, $id); @@ -119,7 +119,7 @@ function wopiCheckFileInfo(string $id, Request $request) { * @return \Symfony\Component\HttpFoundation\Response * The response with file contents. */ - function wopiGetFile(string $id, Request $request) { + public function wopiGetFile(string $id, Request $request) { $token = $request->query->get('access_token'); $jwt_payload = CoolUtils::verifyTokenForId($token, $id); @@ -154,7 +154,7 @@ function wopiGetFile(string $id, Request $request) { * @return \Symfony\Component\HttpFoundation\Response * The response. */ - function wopiPutFile(string $id, Request $request) { + public function wopiPutFile(string $id, Request $request) { $token = $request->query->get('access_token'); $timestamp = $request->headers->get('x-cool-wopi-timestamp'); $modified_by_user = $request->headers->get('x-cool-wopi-ismodifiedbyuser') == 'true'; diff --git a/src/Cool/CoolUtils.php b/src/Cool/CoolUtils.php index 5c212336..a52b3483 100644 --- a/src/Cool/CoolUtils.php +++ b/src/Cool/CoolUtils.php @@ -73,7 +73,7 @@ public static function setMediaSource(Media $media, File $source) { * @return string * The key value. */ - static function getKey() { + public static function getKey() { $default_config = \Drupal::config('collabora_online.settings'); $key_id = $default_config->get('cool')['key_id'];