From 3b5e8833974a793a0005a0d3076acc05e109b777 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Daniel=20Mart=C3=AD?= <mvdan@mvdan.cc>
Date: Sat, 4 Jan 2014 01:09:33 +0100
Subject: [PATCH] Translation string format inconsistencies should not be
 caught in java

They should not exist at all, i.e. our translatebot should not allow them in
(they break things in other places, not just here)
---
 src/org/fdroid/fdroid/SearchResults.java | 21 +++++++++------------
 1 file changed, 9 insertions(+), 12 deletions(-)

diff --git a/src/org/fdroid/fdroid/SearchResults.java b/src/org/fdroid/fdroid/SearchResults.java
index 1a3ac216b..0ee545c98 100644
--- a/src/org/fdroid/fdroid/SearchResults.java
+++ b/src/org/fdroid/fdroid/SearchResults.java
@@ -118,18 +118,15 @@ public class SearchResults extends ListActivity {
 
         TextView tv = (TextView) findViewById(R.id.description);
         String headertext;
-        try {
-            if (apps.size() == 0)
-                headertext = String.format(getString(R.string.searchres_noapps),
-                        mQuery);
-            else if (apps.size() == 1)
-                headertext = String.format(getString(R.string.searchres_oneapp),
-                        mQuery);
-            else
-                headertext = String.format(getString(R.string.searchres_napps),
-                        apps.size(), mQuery);
-        } catch(Exception ex) {
-            headertext = "TRANSLATION ERROR!";
+        if (apps.size() == 0) {
+            headertext = String.format(getString(R.string.searchres_noapps),
+                    mQuery);
+        } else if (apps.size() == 1) {
+            headertext = String.format(getString(R.string.searchres_oneapp),
+                    mQuery);
+        } else {
+            headertext = String.format(getString(R.string.searchres_napps),
+                    apps.size(), mQuery);
         }
         tv.setText(headertext);
         Log.d("FDroid", "Search for '" + mQuery + "' returned " + apps.size()