diff --git a/src/gui/tray/activitylistmodel.h b/src/gui/tray/activitylistmodel.h
index 8fa3fce5d0686..2a99ff0180370 100644
--- a/src/gui/tray/activitylistmodel.h
+++ b/src/gui/tray/activitylistmodel.h
@@ -84,7 +84,7 @@ class ActivityListModel : public QAbstractListModel
     void removeActivityFromActivityList(Activity activity);
     void clearAll();
 
-    int maxActivities() { return _maxActivities; };
+    int maxActivities() const { return _maxActivities; };
 
     Q_INVOKABLE void triggerDefaultAction(int activityIndex);
     Q_INVOKABLE void triggerAction(int activityIndex, int actionIndex);