nextNoteVault #23

Merged
sebastian merged 57 commits from nextNoteVault into master 2025-05-10 06:23:23 +00:00
Showing only changes of commit dfabf7e721 - Show all commits

View File

@ -100,7 +100,19 @@ public class SongSyncModule {
public void getRemotelyModifiedSongData(List<Song> freshlyCreatedSongs) { public void getRemotelyModifiedSongData(List<Song> freshlyCreatedSongs) {
songSyncRepository.loadRemotelyModifiedSongs(songs -> { songSyncRepository.loadRemotelyModifiedSongs(songs -> {
songs.addAll(freshlyCreatedSongs); for(Song song : freshlyCreatedSongs) {
boolean freshlyCreatedSongFound = false;
for(Song s : songs) {
if(s.getServerID().equals(song.getServerID())) {
freshlyCreatedSongFound = true;
break;
}
}
if(!freshlyCreatedSongFound) {
songs.add(song);
}
}
if(songs.isEmpty()) { if(songs.isEmpty()) {
syncViewModel.finishFetching(); syncViewModel.finishFetching();
} else { } else {