Merge pull request #6 from kyori19/fix-notification
Fix notification crashes caused by unknown notification type
This commit is contained in:
commit
801dc9c842
|
@ -195,6 +195,9 @@ public class CacheController{
|
||||||
db.delete(table, null, null);
|
db.delete(table, null, null);
|
||||||
ContentValues values=new ContentValues(3);
|
ContentValues values=new ContentValues(3);
|
||||||
for(Notification n:notifications){
|
for(Notification n:notifications){
|
||||||
|
if(n.type==null){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
values.put("id", n.id);
|
values.put("id", n.id);
|
||||||
values.put("json", MastodonAPIController.gson.toJson(n));
|
values.put("json", MastodonAPIController.gson.toJson(n));
|
||||||
values.put("type", n.type.ordinal());
|
values.put("type", n.type.ordinal());
|
||||||
|
|
Loading…
Reference in New Issue