fix the save button by removing deleted items from spaces then return all other elements status to unchanged

This commit is contained in:
raf-dev1
2025-06-12 14:13:25 +03:00
parent e81b9a853e
commit 0b0e235f26

View File

@ -491,6 +491,12 @@ class SpaceManagementBloc
event.communityUuid,
emit,
);
event.spaces.removeWhere(
(space) => space.status == SpaceStatus.deleted,
);
event.spaces.forEach(
(space) => space.status = SpaceStatus.unchanged,
);
}
} catch (e) {
// emit(SpaceManagementError('Error saving spaces: $e'));