From f9acd7b4f2362402f5a23f80e0a27552ea76e3e6 Mon Sep 17 00:00:00 2001 From: Kalev Lember Date: Fri, 29 Mar 2019 14:31:07 +0100 Subject: Only require for validate, but not validate-relax The plan was to require for validate, so that we would be able to require a version number for flathub, but it accidentally got enabled for validate-relax as well. --- libappstream-glib/as-app-validate.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/libappstream-glib/as-app-validate.c b/libappstream-glib/as-app-validate.c index 945771b..248e9b6 100644 --- a/libappstream-glib/as-app-validate.c +++ b/libappstream-glib/as-app-validate.c @@ -941,10 +941,13 @@ as_app_validate_releases (AsApp *app, AsAppValidateHelper *helper, GError **erro as_format_get_kind (format) != AS_FORMAT_KIND_METAINFO) return TRUE; - /* only for desktop and console apps */ - if (as_app_get_kind (app) == AS_APP_KIND_DESKTOP || - as_app_get_kind (app) == AS_APP_KIND_CONSOLE) { - require_release = TRUE; + /* make the requirements more strict */ + if ((helper->flags & AS_APP_VALIDATE_FLAG_RELAX) == 0) { + /* only for desktop and console apps */ + if (as_app_get_kind (app) == AS_APP_KIND_DESKTOP || + as_app_get_kind (app) == AS_APP_KIND_CONSOLE) { + require_release = TRUE; + } } /* require releases */ -- cgit v1.2.1