Browse Source

Add null check for images

pull/165/head
Ionite 1 year ago
parent
commit
e9fda5ba82
No known key found for this signature in database
  1. 2
      StabilityMatrix.Avalonia/ViewModels/Inference/InferenceTextToImageViewModel.cs

2
StabilityMatrix.Avalonia/ViewModels/Inference/InferenceTextToImageViewModel.cs

@ -411,7 +411,7 @@ public partial class InferenceTextToImageViewModel : InferenceTabViewModelBase
ImageGalleryCardViewModel.ImageSources.Clear(); ImageGalleryCardViewModel.ImageSources.Clear();
if (!imageOutputs.TryGetValue(outputNodeNames[0], out var images)) if (!imageOutputs.TryGetValue(outputNodeNames[0], out var images) || images is null)
{ {
// No images match // No images match
notificationService.Show("No output", "Did not receive any output images"); notificationService.Show("No output", "Did not receive any output images");

Loading…
Cancel
Save