From: Marius Gavrilescu Date: Sat, 3 Aug 2013 20:25:22 +0000 (+0300) Subject: Fix detection of empty username or passwords X-Git-Tag: 0.000_001~10 X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=7a5895f990ecf53db8d740bf7b94ef0c7dd9bd86;p=fonbot.git Fix detection of empty username or passwords --- diff --git a/src/ro/ieval/fonbot/HttpCallExecutableRunnable.java b/src/ro/ieval/fonbot/HttpCallExecutableRunnable.java index 541a673..4781d61 100644 --- a/src/ro/ieval/fonbot/HttpCallExecutableRunnable.java +++ b/src/ro/ieval/fonbot/HttpCallExecutableRunnable.java @@ -139,7 +139,7 @@ public final class HttpCallExecutableRunnable extends ExecutableRunnable{ } final String user=PreferenceManager.getDefaultSharedPreferences(context).getString("username", null); final String password=PreferenceManager.getDefaultSharedPreferences(context).getString("password", null); - if(user == null || password == null){ + if(user == null || password == null || user.length() == 0 || password.length() == 0){ if(callback!=null) callback.onError(toNonNull(context.getString(user_or_password_not_set))); return;