diff options
Diffstat (limited to 'src/PhotoPage.vala')
| -rw-r--r-- | src/PhotoPage.vala | 8 | 
1 files changed, 7 insertions, 1 deletions
| diff --git a/src/PhotoPage.vala b/src/PhotoPage.vala index a28ab44..3ab0f6b 100644 --- a/src/PhotoPage.vala +++ b/src/PhotoPage.vala @@ -835,7 +835,9 @@ public abstract class EditingHostPage : SinglePhotoPage {          photo_changing(photo);          DataView view = get_view().get_view_for_source(photo); -        assert(view != null); +        if (view == null) { +            return; +        }          // Select photo.          get_view().unselect_all(); @@ -1255,6 +1257,10 @@ public abstract class EditingHostPage : SinglePhotoPage {      }      private void quick_update_pixbuf() { +        if (get_photo() == null) { +            return; +        } +          Gdk.Pixbuf? pixbuf = cache.get_ready_pixbuf(get_photo());          if (pixbuf != null) {              set_pixbuf(pixbuf, get_photo().get_dimensions()); | 
