Add local account sync result notification
This commit is contained in:
parent
46712f4c5e
commit
2453f35179
@ -22,6 +22,7 @@ import com.readrops.readropslibrary.localfeed.RSSQueryResult;
|
||||
import com.readrops.readropslibrary.localfeed.atom.ATOMFeed;
|
||||
import com.readrops.readropslibrary.localfeed.json.JSONFeed;
|
||||
import com.readrops.readropslibrary.localfeed.rss.RSSFeed;
|
||||
import com.readrops.readropslibrary.services.SyncResult;
|
||||
import com.readrops.readropslibrary.utils.LibUtils;
|
||||
import com.readrops.readropslibrary.utils.ParseException;
|
||||
import com.readrops.readropslibrary.utils.UnknownFormatException;
|
||||
@ -44,6 +45,8 @@ public class LocalFeedRepository extends ARepository<Void> {
|
||||
|
||||
public LocalFeedRepository(@NonNull Context context, @Nullable Account account) {
|
||||
super(context, account);
|
||||
|
||||
syncResult = new SyncResult();
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -247,6 +250,7 @@ public class LocalFeedRepository extends ARepository<Void> {
|
||||
}
|
||||
}
|
||||
|
||||
syncResult.getItems().addAll(itemsToInsert);
|
||||
database.itemDao().insert(itemsToInsert);
|
||||
}
|
||||
|
||||
|
@ -6,7 +6,7 @@ import com.readrops.readropsdb.entities.Item
|
||||
|
||||
class SyncResult {
|
||||
|
||||
var items: List<Item> = listOf()
|
||||
var items: List<Item> = mutableListOf()
|
||||
|
||||
var feeds: List<Feed> = listOf()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user