[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] r21458: {website} do not care if based-on-revision is missing (website/trunk/include)



Author: runa
Date: 2010-01-20 17:09:12 +0000 (Wed, 20 Jan 2010)
New Revision: 21458

Modified:
   website/trunk/include/functions.wmi
Log:
do not care if based-on-revision is missing

Modified: website/trunk/include/functions.wmi
===================================================================
--- website/trunk/include/functions.wmi	2010-01-20 13:05:42 UTC (rev 21457)
+++ website/trunk/include/functions.wmi	2010-01-20 17:09:12 UTC (rev 21458)
@@ -50,12 +50,11 @@
 	my ($dir, $lang, $page) = @_;
 	my $translation = getMetadata("$dir/$lang/$page");
 
-	die ("Cannot find 'Based-On-Revision' header in translations's translation metadata of $lang/$page") unless exists $translation->{'Based-On-Revision'};
-
-	my ($rev) = $translation->{'Based-On-Revision'};
-	if ($rev eq '') { $rev = '(unknown)'; };
-
-	return $rev
+	if (exists $translation->{'Based-On-Revision'}) {
+		return $translation->{'Based-On-Revision'};
+	} else {
+		 return '(unknown)';
+	}
 };
 sub translation_get_basedonrevision() {
 	translation_get_basedonrevision_langfile(".", "$(LANG)", $WML_SRC_FILENAME);