Bug 1081317: Don't create redundant temporary objects when converting primitives to strings. r=rnewman

* * *
Bug 1081317: Don't create redundant temporary objects when converting primitives to strings. r=rnewman
This commit is contained in:
Chris Kitching 2014-10-10 21:53:22 +01:00
parent 1c7d9eeb0a
commit ec1a4b949f
2 changed files with 2 additions and 2 deletions

View File

@ -176,7 +176,7 @@ public class PasswordsProvider extends SQLiteBridgeContentProvider {
String guid = Utils.generateGuid();
values.put(Passwords.GUID, guid);
}
String nowString = new Long(now).toString();
String nowString = Long.toString(now);
DBUtils.replaceKey(values, null, Passwords.HOSTNAME, "");
DBUtils.replaceKey(values, null, Passwords.HTTP_REALM, "");
DBUtils.replaceKey(values, null, Passwords.FORM_SUBMIT_URL, "");

View File

@ -239,7 +239,7 @@ public class ConfigurationMigrator {
}
if (numClients > -1) {
Logger.debug(LOG_TAG, "Migrated clients count.");
accountManager.setUserData(account, V1_PREF_NUM_CLIENTS, new Long(numClients).toString());
accountManager.setUserData(account, V1_PREF_NUM_CLIENTS, Long.toString(numClients));
count += 1;
}
return count;