davx5-ose
davx5-ose copied to clipboard
Fix setup through nextcloud app (intent) not working
Purpose
The nextcloud login/setup flow could not be started via intent. This fixes it.
Short description
LoginActivity:
- Now using previously unused
intentToInitialLoginType()
to determine login type from intent. - Use
selectLoginType()
to change the login type accordingly
LoginScreenModel:
- Alter
selectLoginType()
to also update the ui state of the login details page. Previously it only updated the ui state of the login type page. - Small lint fix
See also: Creation of intent in nextcloud app.
Testing
Intent for testing:
adb shell am start -e url "https://davtest.dev001.net/nextcloud" -e loginFlow 1 at.bitfire.davdroid/at.bitfire.davdroid.ui.setup.LoginActivity
Checklist
- [X] The PR has a proper title, description and label.
- [x] I have self-reviewed the PR.
- [x] I have added documentation to complex functions and functions that can be used by other modules.
- [X] I have added reasonable tests or consciously decided to not add tests.