X-Git-Url: https://git.ktnx.net/?p=mobile-ledger.git;a=blobdiff_plain;f=app%2Fsrc%2Fmain%2Fjava%2Fnet%2Fktnx%2Fmobileledger%2Fui%2Factivity%2FSplashActivity.java;h=2a238adc61333e826c5c5340034e26c311a11f39;hp=4205c80b5775084c898792bdca8c3115479b0bee;hb=93545c6fbf1244fbd96ecfc50e1115dbdc25f9ae;hpb=1c3647f273df2f15ef299896c24cda95c6119988 diff --git a/app/src/main/java/net/ktnx/mobileledger/ui/activity/SplashActivity.java b/app/src/main/java/net/ktnx/mobileledger/ui/activity/SplashActivity.java index 4205c80b..2a238adc 100644 --- a/app/src/main/java/net/ktnx/mobileledger/ui/activity/SplashActivity.java +++ b/app/src/main/java/net/ktnx/mobileledger/ui/activity/SplashActivity.java @@ -1,5 +1,5 @@ /* - * Copyright © 2020 Damyan Ivanov. + * Copyright © 2021 Damyan Ivanov. * This file is part of MoLe. * MoLe is free software: you can distribute it and/or modify it * under the term of the GNU General Public License as published by @@ -100,10 +100,10 @@ public class SplashActivity extends CrashReportingActivity { private static class DatabaseInitTask extends AsyncTask { @Override protected Void doInBackground(Void... voids) { - MobileLedgerProfile.loadAllFromDB(null); + MobileLedgerProfile.loadAllFromDB(0); - String profileUUID = MLDB.getOption(MLDB.OPT_PROFILE_UUID, null); - MobileLedgerProfile startupProfile = Data.getProfile(profileUUID); + long profileId = MLDB.getLongOption(MLDB.OPT_PROFILE_ID, 0); + MobileLedgerProfile startupProfile = Data.getProfile(profileId); if (startupProfile != null) Data.postCurrentProfile(startupProfile); return null;