Refactored sync_storage for usage of indexed collections