mirror of
https://github.com/nextcloud/server.git
synced 2026-06-08 16:26:59 -04:00
Merge pull request #48976 from nextcloud/backport/48788/stable30
[stable30] fix: add PasswordConfirmationRequired to the external storages mentioned in review
This commit is contained in:
commit
c5a15be4ea
3 changed files with 7 additions and 0 deletions
|
|
@ -9,6 +9,7 @@ namespace OCA\Files_External\Controller;
|
|||
use OCA\Files_External\NotFoundException;
|
||||
use OCA\Files_External\Service\GlobalStoragesService;
|
||||
use OCP\AppFramework\Http;
|
||||
use OCP\AppFramework\Http\Attribute\PasswordConfirmationRequired;
|
||||
use OCP\AppFramework\Http\DataResponse;
|
||||
use OCP\IConfig;
|
||||
use OCP\IGroupManager;
|
||||
|
|
@ -69,6 +70,7 @@ class GlobalStoragesController extends StoragesController {
|
|||
*
|
||||
* @return DataResponse
|
||||
*/
|
||||
#[PasswordConfirmationRequired]
|
||||
public function create(
|
||||
$mountPoint,
|
||||
$backend,
|
||||
|
|
@ -134,6 +136,7 @@ class GlobalStoragesController extends StoragesController {
|
|||
*
|
||||
* @return DataResponse
|
||||
*/
|
||||
#[PasswordConfirmationRequired]
|
||||
public function update(
|
||||
$id,
|
||||
$mountPoint,
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ use OCA\Files_External\NotFoundException;
|
|||
use OCA\Files_External\Service\StoragesService;
|
||||
use OCP\AppFramework\Controller;
|
||||
use OCP\AppFramework\Http;
|
||||
use OCP\AppFramework\Http\Attribute\PasswordConfirmationRequired;
|
||||
use OCP\AppFramework\Http\DataResponse;
|
||||
use OCP\Files\StorageNotAvailableException;
|
||||
use OCP\IConfig;
|
||||
|
|
@ -300,6 +301,7 @@ abstract class StoragesController extends Controller {
|
|||
*
|
||||
* @return DataResponse
|
||||
*/
|
||||
#[PasswordConfirmationRequired]
|
||||
public function destroy($id) {
|
||||
try {
|
||||
$this->service->removeStorage($id);
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@ use OCA\Files_External\NotFoundException;
|
|||
use OCA\Files_External\Service\UserGlobalStoragesService;
|
||||
use OCP\AppFramework\Http;
|
||||
use OCP\AppFramework\Http\Attribute\NoAdminRequired;
|
||||
use OCP\AppFramework\Http\Attribute\PasswordConfirmationRequired;
|
||||
use OCP\AppFramework\Http\DataResponse;
|
||||
use OCP\IConfig;
|
||||
use OCP\IGroupManager;
|
||||
|
|
@ -136,6 +137,7 @@ class UserGlobalStoragesController extends StoragesController {
|
|||
* @return DataResponse
|
||||
*/
|
||||
#[NoAdminRequired]
|
||||
#[PasswordConfirmationRequired]
|
||||
public function update(
|
||||
$id,
|
||||
$backendOptions,
|
||||
|
|
|
|||
Loading…
Reference in a new issue