Skip to content
This repository was archived by the owner on Jul 7, 2024. It is now read-only.

Commit d10d819

Browse files
committed
Bug fix (crash on null list)
1 parent 1745889 commit d10d819

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

app/build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ android {
2929
applicationId "com.shalchian.sarrafi"
3030
minSdkVersion 21
3131
targetSdkVersion 30
32-
versionCode 14
33-
versionName "1.1.4"
32+
versionCode 15
33+
versionName "1.1.5"
3434
multiDexEnabled true
3535
android.defaultConfig.vectorDrawables.useSupportLibrary = true
3636
}
@@ -119,7 +119,7 @@ dependencies {
119119
implementation 'com.shreyaspatil:MaterialDialog:2.1'
120120

121121
//Google Play Core
122-
implementation 'com.google.android.play:core:1.8.0'
122+
implementation 'com.google.android.play:core:1.8.2'
123123

124124
// Material Navigation View Library
125125
implementation 'com.shreyaspatil:MaterialNavigationView:1.2'

app/src/main/java/com/shalchian/sarrafi/activity/EditFavoriteListActivity.java

+3
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,9 @@ protected void onCreate(Bundle savedInstanceState) {
8484
status_text = findViewById(R.id.status_text);
8585

8686
ArrayList<FavoriteModel> list = DatabaseManager.getInstance().getFavoriteList();
87+
if (list == null)
88+
list = new ArrayList<>();
89+
8790
adapter = new EditListAdapter(list, this);
8891

8992
RecyclerView recyclerView = findViewById(R.id.fav_list_rcv);

0 commit comments

Comments
 (0)