Skip to content

Commit d3f51c8

Browse files
authored
Merge pull request #4300 from anyproto/ios-5485-release-to-dev
Ios 5485 release to dev
2 parents ddd0e56 + f5de28f commit d3f51c8

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

AnyTypeTests/Services/SetContentViewDataBuilderTests.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ struct SetContentViewDataBuilderTests {
3939
}
4040

4141
@Test func testBuildChatPreview_NilSpaceView_UsesDefaultNotificationMode() {
42-
let creator = Participant.mock(id: "user1", globalName: "Test User")
42+
let creator = Participant.mock(id: "user1", localName: "Test User")
4343
let lastMessage = LastMessagePreview(
4444
id: "msg1",
4545
creator: creator,
@@ -93,7 +93,7 @@ struct SetContentViewDataBuilderTests {
9393
}
9494

9595
@Test func testBuildChatPreview_ValidPreview_BuildsCompleteModel() {
96-
let creator = Participant.mock(id: "user1", globalName: "John Doe")
96+
let creator = Participant.mock(id: "user1", localName: "John Doe")
9797
let lastMessage = LastMessagePreview(
9898
id: "msg1",
9999
creator: creator,

Anytype/Sources/PresentationLayer/Modules/HomeWidgets/Widgets/Link/LinkWidgetViewModel.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ final class LinkWidgetViewModel: ObservableObject {
9595
let isMuted = !(spaceView?.effectiveNotificationMode(for: linkedObjectDetails.id).isUnmutedAll ?? true)
9696

9797
badgeModel = MessagePreviewModel(
98-
creatorTitle: lastMessage.creator?.globalName,
98+
creatorTitle: lastMessage.creator?.title,
9999
text: lastMessage.text,
100100
attachments: Array(attachments),
101101
localizedAttachmentsText: lastMessage.localizedAttachmentsText,

Anytype/Sources/PresentationLayer/Modules/SpaceHub/Subviews/SpaceCard/NewSpaceCardLastMessageView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ struct NewSpaceCardLastMessageView: View {
7070
}
7171

7272
HStack(spacing: 2) {
73-
if let creatorTitle = model.creatorTitle {
73+
if supportsMultiChats, let creatorTitle = model.creatorTitle {
7474
AnytypeText("\(creatorTitle):", style: .chatPreviewRegular)
7575
.foregroundColor(.Text.transparentSecondary)
7676
.lineLimit(1)

Anytype/Sources/PresentationLayer/TextEditor/Set/Views/Models/SetContentViewDataBuilder.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,7 @@ final class SetContentViewDataBuilder: SetContentViewDataBuilderProtocol {
305305
let isMuted = !(spaceView?.effectiveNotificationMode(for: objectId).isUnmutedAll ?? true)
306306

307307
return MessagePreviewModel(
308-
creatorTitle: lastMessage.creator?.globalName,
308+
creatorTitle: lastMessage.creator?.title,
309309
text: lastMessage.text,
310310
attachments: Array(attachments),
311311
localizedAttachmentsText: lastMessage.localizedAttachmentsText,

0 commit comments

Comments
 (0)