Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Client Repositories #14722

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open

Add Client Repositories #14722

wants to merge 6 commits into from

Conversation

alperozturk96
Copy link
Collaborator

@alperozturk96 alperozturk96 commented Mar 24, 2025

  • Tests written, or not not needed

In our codebase, we have duplicated logic for creating OwnCloudClient and NextcloudClient instances. In Java files, this requires manually creating a new thread, handling exceptions, and switching back to the main thread after initializing the client. While Kotlin simplifies this process, it still requires explicit handling.

Performing networking operations directly within activities leads to bloated and less maintainable code. This pull request introduces a repository pattern to encapsulate client creation and networking logic, improving code reusability, separation of concerns, and maintainability.

Copy link

Codacy

Lint

TypemasterPR
Warnings5454
Errors1111

SpotBugs

CategoryBaseNew
Bad practice6565
Correctness5858
Dodgy code292292
Experimental11
Internationalization77
Malicious code vulnerability11
Multithreaded correctness77
Performance5151
Security1818
Total500500

Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
@alperozturk96 alperozturk96 force-pushed the add-client-repository branch from d0165a1 to d8d085d Compare April 2, 2025 13:34
Copy link

github-actions bot commented Apr 2, 2025

APK file: https://www.kaminsky.me/nc-dev/android-artifacts/14722.apk

qrcode

To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.

Copy link

github-actions bot commented Apr 2, 2025

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