Skip to content

Commit 4f603f3

Browse files
authored
Fix crash when clipboard changes before InteractionViewModel is set (#2829)
1 parent 30a5435 commit 4f603f3

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Files/App.xaml.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,11 @@ private void CoreWindow_Activated(CoreWindow sender, WindowActivatedEventArgs ar
176176

177177
private void Clipboard_ContentChanged(object sender, object e)
178178
{
179+
if (App.InteractionViewModel == null)
180+
{
181+
return;
182+
}
183+
179184
try
180185
{
181186
// Clipboard.GetContent() will throw UnauthorizedAccessException

0 commit comments

Comments
 (0)