Skip to content

Commit

Permalink
Location event body representation (#1368)
Browse files Browse the repository at this point in the history
* Change GeoURI body format

* Update location event representation
  • Loading branch information
alfogrillo authored Jul 20, 2023
1 parent f0ca152 commit ed27aa9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -675,6 +675,6 @@ private extension RoomFlowCoordinator {

private extension GeoURI {
var bodyMessage: String {
String(format: "Location was shared at %@ as of %@", string, Date().description)
"Location was shared at \(string)"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ struct RoomEventStringBuilder {
message = L10n.commonVideo
case .file:
message = L10n.commonFile
case .location:
message = L10n.commonSharedLocation
default:
message = messageContent.body()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ struct LocationRoomTimelineItem: EventBasedMessageTimelineItemProtocol, Equatabl
let content: LocationRoomTimelineItemContent

var body: String {
content.body
L10n.commonSharedLocation
}

var replyDetails: TimelineItemReplyDetails?
Expand Down

0 comments on commit ed27aa9

Please sign in to comment.