File tree Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -150,14 +150,10 @@ internal async Task SendMessageButton_Click(TextBox messageTextBox)
150
150
151
151
public void TrySelectConversation ( string conversationId )
152
152
{
153
- if ( ConversationsDictionary . ContainsKey ( conversationId ) )
153
+ if ( conversationId != null && ConversationsDictionary . ContainsKey ( conversationId ) )
154
154
{
155
155
SelectedConversation = ConversationsDictionary [ conversationId ] ;
156
156
}
157
- else
158
- {
159
- Logger . LogError ( "TrySelectConversation could not select conversation: key is not present" ) ;
160
- }
161
157
}
162
158
163
159
public void ConversationsList_SelectionChanged ( object sender , SelectionChangedEventArgs e )
@@ -278,7 +274,6 @@ public void ReplaceConversationList(List<SignalConversation> conversations)
278
274
ConversationsDictionary . Clear ( ) ;
279
275
Conversations . Clear ( ) ;
280
276
Conversations . AddRange ( conversations ) ;
281
-
282
277
foreach ( var c in Conversations )
283
278
{
284
279
ConversationsDictionary . Add ( c . ThreadId , c ) ;
Original file line number Diff line number Diff line change @@ -86,6 +86,7 @@ protected override void OnNavigatedTo(NavigationEventArgs e)
86
86
SwitchToStyle ( GetCurrentViewStyle ( ) ) ;
87
87
MainPanel . DisplayMode = SplitViewDisplayMode . CompactInline ;
88
88
Frame . SizeChanged += Frame_SizeChanged ;
89
+ Vm . TrySelectConversation ( Vm . RequestedConversationId ) ;
89
90
}
90
91
91
92
protected override void OnNavigatingFrom ( NavigatingCancelEventArgs e )
You can’t perform that action at this time.
0 commit comments