From 41c3b2e5e7ab9f45406298ba7d497fb473111546 Mon Sep 17 00:00:00 2001 From: Richard Hughes Date: Fri, 3 Dec 2021 11:48:03 +0000 Subject: Fix validation of translated captions when LANG is not C Fixes https://github.com/hughsie/appstream-glib/issues/422 --- libappstream-glib/as-app-validate.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libappstream-glib/as-app-validate.c b/libappstream-glib/as-app-validate.c index 7de7814..feaa466 100644 --- a/libappstream-glib/as-app-validate.c +++ b/libappstream-glib/as-app-validate.c @@ -137,7 +137,7 @@ as_app_validate_has_first_word_capital (AsAppValidateHelper *helper, const gchar } /* is the first word the project name */ - if (g_strcmp0 (first_word, as_app_get_name (helper->app, NULL)) == 0) + if (g_strcmp0 (first_word, as_app_get_name (helper->app, "C")) == 0) return TRUE; return FALSE; @@ -651,7 +651,7 @@ as_app_validate_screenshot (AsScreenshot *ss, AsAppValidateHelper *helper) im = g_ptr_array_index (images, i); as_app_validate_image (im, helper); } - tmp = as_screenshot_get_caption (ss, NULL); + tmp = as_screenshot_get_caption (ss, "C"); if (tmp != NULL) { str_len = (guint) strlen (tmp); if (str_len < length_caption_min) { @@ -1775,7 +1775,7 @@ as_app_validate (AsApp *app, guint32 flags, GError **error) } /* developer_name */ - name = as_app_get_developer_name (app, NULL); + name = as_app_get_developer_name (app, "C"); if (name != NULL) { str_len = (guint) strlen (name); if (str_len < length_name_min) { -- cgit v1.2.1