Skip to content

Commit

Permalink
always use media repository to update alt text
Browse files Browse the repository at this point in the history
  • Loading branch information
AkesiSeli committed Dec 15, 2024
1 parent bfd0c4d commit 048c214
Showing 1 changed file with 4 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1183,18 +1183,10 @@ class ComposerViewModel(
) {
screenModelScope.launch {
val successful =
if (shouldUserPhotoRepository) {
photoRepository.update(
id = attachment.id,
album = attachment.album.orEmpty(),
alt = description,
)
} else {
mediaRepository.update(
id = attachment.id,
alt = description,
)
}
mediaRepository.update(
id = attachment.id,
alt = description,
)

if (successful) {
updateAttachmentInState(attachment.id) {
Expand Down

0 comments on commit 048c214

Please # to comment.