From bac897381cc1ddaf741004c5590474b0145b8d57 Mon Sep 17 00:00:00 2001 From: Solomon Peachy Date: Fri, 5 Mar 2021 12:42:23 -0500 Subject: updatelang: Handle/flag the bad data that led to english-us breaking Change-Id: Ifffea9557d50ab5a103e13473ebe074ae1aa7b6d --- tools/updatelang | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tools/updatelang') diff --git a/tools/updatelang b/tools/updatelang index 601ec3d297..48f447d074 100755 --- a/tools/updatelang +++ b/tools/updatelang @@ -307,7 +307,7 @@ foreach my $id (@langorder) { } } foreach my $tgt (keys(%ep)) { - if (!defined($lp{$tgt})) { + if (!defined($lp{$tgt}) || ($lp{$tgt} eq 'none')) { # If it doesn't exist in the language, copy it from English if ($ep{$tgt} ne 'none' && $ep{$tgt} ne '' ) { $lang{$id}{'notes'} .= "### The section for '$id:$tgt' is missing! Copying from english!\n"; @@ -356,7 +356,7 @@ foreach my $id (@langorder) { } } foreach my $tgt (keys(%ep)) { - if (!defined($lp{$tgt})) { + if (!defined($lp{$tgt}) || ($lp{$tgt} eq 'none')) { # If it doesn't exist in the language, copy it from English if ($ep{$tgt} ne 'none' && $ep{$tgt} ne '' ) { $lang{$id}{'notes'} .= "### The section for '$id:$tgt' is missing! Copying from english!\n"; -- cgit v1.2.3