Skip to content

[stable-35.0.x] improve: fetch-template - #17645

Merged
alperozturk96 merged 5 commits into
stable-35.0.xfrom
backport/17569/stable-35.0.x
Sep 16, 2026
Merged

alperozturk96 merged 5 commits into
stable-35.0.xfrom
backport/17569/stable-35.0.x

Conversation

@backportbot

@backportbot backportbot Bot commented Sep 15, 2026

Copy link
Copy Markdown

Backport of PR #17569

Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
The redundant elvis on fileNames belongs to neither the crash fix nor the
Kotlin conversion, so it goes back to its previous form to keep this branch
scoped to one concern.

Assisted-by: ClaudeCode:claude-opus-5
When the template list comes back empty the dialog had no selected template,
so the extension check compared the typed name against null and reported
"Extension cannot be changed" for every name while Create stayed disabled.

Resolve the filename into a single state, treat "no template selected" as its
own state, hold the error back until the user has typed, and close the dialog
when no template could be loaded.

Assisted-by: ClaudeCode:claude-opus-5
Fail-fast control flow, JSON node names as constants, and URL building and
response parsing split into separate functions. Behaviour is unchanged.

Assisted-by: ClaudeCode:claude-opus-5
@github-actions

Copy link
Copy Markdown

blue-Light-Screenshot test failed, but no output was generated. Maybe a preliminary stage failed.

@github-actions

Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/34976290423/artifacts/10401504473
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@github-actions

Copy link
Copy Markdown

SpotBugs

CategoryBaseNew
Bad practice032
Correctness058
Dodgy code0186
Experimental01
Malicious code vulnerability02
Multithreaded correctness026
Performance037
Security018
Total0360

SpotBugs increased!

@alperozturk96
alperozturk96 merged commit a616361 into stable-35.0.x Sep 16, 2026
12 of 19 checks passed
@alperozturk96
alperozturk96 deleted the backport/17569/stable-35.0.x branch September 16, 2026 11:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant