Merge pull request #946 from owncloud/upgrading_account_manager
[pub/Android/ownCloud.git] / src / com / owncloud / android / authentication / AuthenticatorActivity.java
index 6514ef7..f245900 100644 (file)
@@ -1483,6 +1483,13 @@ public class AuthenticatorActivity extends AccountAuthenticatorActivity
                 );\r
             }\r
 \r
+            // include account version with the new account\r
+            mAccountMgr.setUserData(\r
+                mAccount,\r
+                Constants.KEY_OC_ACCOUNT_VERSION,\r
+                Integer.toString(AccountUtils.ACCOUNT_VERSION)\r
+            );\r
+\r
             /// add the new account as default in preferences, if there is none already\r
             Account defaultAccount = AccountUtils.getCurrentOwnCloudAccount(this);\r
             if (defaultAccount == null) {\r