Merge pull request #8356 from nextcloud/avatarInAccount

Avatar generation can take long, so better check if ChooseAccountDialogFragment is still active
This commit is contained in:
Andy Scherzinger 2021-05-14 09:47:27 +02:00 committed by GitHub
commit a6c87ac78b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -23,7 +23,7 @@ upload() {
echo "Uploaded failing tests to https://www.kaminsky.me/nc-dev/android-integrationTests/$REMOTE_FOLDER"
curl > /dev/null 2>&1 -u $GITHUB_USER:$GITHUB_PASSWORD -X POST https://api.github.com/repos/nextcloud/android/issues/$PR/comments \
curl -u $GITHUB_USER:$GITHUB_PASSWORD -X POST https://api.github.com/repos/nextcloud/android/issues/$PR/comments \
-d "{ \"body\" : \"$BRANCH_TYPE test failed: https://www.kaminsky.me/nc-dev/android-integrationTests/$REMOTE_FOLDER \" }"
exit 1

View File

@ -193,7 +193,9 @@ class ChooseAccountDialogFragment :
}
override fun avatarGenerated(avatarDrawable: Drawable?, callContext: Any?) {
binding.currentAccount.userIcon.setImageDrawable(avatarDrawable)
if (_binding != null) {
binding.currentAccount.userIcon.setImageDrawable(avatarDrawable)
}
}
override fun onAccountClicked(user: User?) {