Skip to content

Commit af8189f

Browse files
authored
Merge pull request #50524 from nextcloud/fix/destination-drop-check
2 parents 16921d7 + e7d9985 commit af8189f

File tree

9 files changed

+16
-11
lines changed

9 files changed

+16
-11
lines changed

apps/files_sharing/src/components/NewFileRequestDialog.vue

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -218,10 +218,9 @@ export default defineComponent({
218218
methods: {
219219
onPageNext() {
220220
const form = this.$refs.form as HTMLFormElement
221-
if (!form.checkValidity()) {
222-
form.reportValidity()
223-
return
224-
}
221+
222+
// Reset custom validity
223+
form.querySelectorAll('input').forEach(input => input.setCustomValidity(''))
225224
226225
// custom destination validation
227226
// cannot share root
@@ -232,6 +231,12 @@ export default defineComponent({
232231
return
233232
}
234233
234+
// If the form is not valid, show the error message
235+
if (!form.checkValidity()) {
236+
form.reportValidity()
237+
return
238+
}
239+
235240
if (this.currentStep === STEP.FIRST) {
236241
this.currentStep = STEP.SECOND
237242
return

dist/1191-1191.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

dist/1191-1191.js.map.license

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/9835-9835.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/9835-9835.js.map.license

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
9835-9835.js.license

dist/files_sharing-init.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/files_sharing-init.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)