mirror of
https://github.com/nextcloud/server.git
synced 2026-06-10 17:23:59 -04:00
refactor(files_versions): Replace security annotations with respective attributes
Signed-off-by: provokateurin <kate@provokateurin.de>
This commit is contained in:
parent
212a621697
commit
2c8f6a009a
1 changed files with 4 additions and 3 deletions
|
|
@ -8,6 +8,8 @@ namespace OCA\Files_Versions\Controller;
|
|||
use OCA\Files_Versions\Versions\IVersionManager;
|
||||
use OCP\AppFramework\Controller;
|
||||
use OCP\AppFramework\Http;
|
||||
use OCP\AppFramework\Http\Attribute\NoAdminRequired;
|
||||
use OCP\AppFramework\Http\Attribute\NoCSRFRequired;
|
||||
use OCP\AppFramework\Http\DataResponse;
|
||||
use OCP\AppFramework\Http\FileDisplayResponse;
|
||||
use OCP\Files\IRootFolder;
|
||||
|
|
@ -47,9 +49,6 @@ class PreviewController extends Controller {
|
|||
}
|
||||
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
* @NoCSRFRequired
|
||||
*
|
||||
* Get the preview for a file version
|
||||
*
|
||||
* @param string $file Path of the file
|
||||
|
|
@ -62,6 +61,8 @@ class PreviewController extends Controller {
|
|||
* 400: Getting preview is not possible
|
||||
* 404: Preview not found
|
||||
*/
|
||||
#[NoAdminRequired]
|
||||
#[NoCSRFRequired]
|
||||
public function getPreview(
|
||||
string $file = '',
|
||||
int $x = 44,
|
||||
|
|
|
|||
Loading…
Reference in a new issue