mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-06-16 21:01:01 +02:00
Merge pull request #657 from greenart7c3/nip-98
fix crash when uploading images/videos using external signer
This commit is contained in:
commit
a2f0c7f548
@ -322,6 +322,7 @@ open class NewPostViewModel() : ViewModel() {
|
|||||||
createNIP95Record(it.readBytes(), contentType, alt, sensitiveContent, relayList = relayList)
|
createNIP95Record(it.readBytes(), contentType, alt, sensitiveContent, relayList = relayList)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
viewModelScope.launch(Dispatchers.IO) {
|
||||||
ImageUploader.uploadImage(
|
ImageUploader.uploadImage(
|
||||||
uri = fileUri,
|
uri = fileUri,
|
||||||
contentType = contentType,
|
contentType = contentType,
|
||||||
@ -345,6 +346,7 @@ open class NewPostViewModel() : ViewModel() {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
onError = {
|
onError = {
|
||||||
isUploadingImage = false
|
isUploadingImage = false
|
||||||
|
Loading…
x
Reference in New Issue
Block a user