Skip to content

Commit

Permalink
Merge pull request #41525 from nextcloud/backport/41520/stable23
Browse files Browse the repository at this point in the history
[stable23] Finish password confirmation
  • Loading branch information
blizzz authored Nov 16, 2023
2 parents c32b5af + b44c655 commit 497c24f
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 16 deletions.
22 changes: 11 additions & 11 deletions apps/workflowengine/js/workflowengine.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion apps/workflowengine/js/workflowengine.js.map

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions apps/workflowengine/lib/Controller/AWorkflowController.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ public function show(string $id): DataResponse {
}

/**
* @PasswordConfirmationRequired
* @throws OCSBadRequestException
* @throws OCSForbiddenException
* @throws OCSException
Expand Down Expand Up @@ -127,6 +128,7 @@ public function create(
}

/**
* @PasswordConfirmationRequired
* @throws OCSBadRequestException
* @throws OCSForbiddenException
* @throws OCSException
Expand Down Expand Up @@ -155,6 +157,7 @@ public function update(
}

/**
* @PasswordConfirmationRequired
* @throws OCSBadRequestException
* @throws OCSForbiddenException
* @throws OCSException
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ public function show(string $id): DataResponse {

/**
* @NoAdminRequired
* @PasswordConfirmationRequired
* @throws OCSBadRequestException
* @throws OCSForbiddenException
*/
Expand All @@ -90,6 +91,7 @@ public function create(string $class, string $name, array $checks, string $opera

/**
* @NoAdminRequired
* @PasswordConfirmationRequired
* @throws OCSBadRequestException
* @throws OCSForbiddenException
*/
Expand All @@ -99,6 +101,7 @@ public function update(int $id, string $name, array $checks, string $operation,

/**
* @NoAdminRequired
* @PasswordConfirmationRequired
* @throws OCSForbiddenException
*/
public function destroy(int $id): DataResponse {
Expand Down
7 changes: 3 additions & 4 deletions apps/workflowengine/src/store.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,8 @@ const store = new Vuex.Store({
context.commit('addRule', rule)
})
},
createNewRule(context, rule) {
async createNewRule(context, rule) {
await confirmPassword()
let entity = null
let events = []
if (rule.isComplex === false && rule.fixedEntity === '') {
Expand Down Expand Up @@ -119,9 +120,7 @@ const store = new Vuex.Store({
context.commit('removeRule', rule)
},
async pushUpdateRule(context, rule) {
if (context.state.scope === 0) {
await confirmPassword()
}
await confirmPassword()
let result
if (rule.id < 0) {
result = await axios.post(getApiUrl(''), rule)
Expand Down

0 comments on commit 497c24f

Please sign in to comment.