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




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

    base-model: Be more strict about what is acceptable

 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]