[gnome-photos/wip/rishi/assert-more: 3/6] base-model: Be more strict about what is acceptable




commit cb41656dc1c661f779f136d7e6f17be84392c599
Author: Debarshi Ray <debarshir gnome org>
Date:   Sun Mar 14 18:39:05 2021 +0100

    base-model: Be more strict about what is acceptable
    
    https://gitlab.gnome.org/GNOME/gnome-photos/-/merge_requests/179

 src/photos-base-model.c | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/src/photos-base-model.c b/src/photos-base-model.c
index 775d606a..c24b4b9c 100644
--- a/src/photos-base-model.c
+++ b/src/photos-base-model.c
@@ -196,5 +196,6 @@ photos_base_model_new (PhotosBaseManager *mngr)
 GMenu *
 photos_base_model_get_model (PhotosBaseModel *self)
 {
+  g_return_val_if_fail (PHOTOS_IS_BASE_MODEL (self), NULL);
   return self->model;
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]