async def update_sync(
        self,
        db: AsyncSession,
        sync_id: UUID,
        sync_update: schemas.SyncUpdate,
        current_user: schemas.User,
    ) -> schemas.Sync:
        """Update a sync configuration.

        Args:
        ----
            db (AsyncSession): The database session.
            sync_id (UUID): The ID of the sync to update.
            sync_update (schemas.SyncUpdate): The sync update data.
            current_user (schemas.User): The current user.

        Returns:
        -------
            schemas.Sync: The updated sync.

        Raises:
        ------
            HTTPException: If the sync is not found.
        """
        sync = await crud.sync.get(
            db=db, id=sync_id, current_user=current_user, with_connections=False
        )
        if not sync:
            raise HTTPException(status_code=404, detail="Sync not found")

        await crud.sync.update(db=db, db_obj=sync, obj_in=sync_update, current_user=current_user)
        updated_sync = await crud.sync.get(
            db=db, id=sync_id, current_user=current_user, with_connections=True
        )
        return updated_sync
Update a sync configuration.

        Args:
        ----
            db (AsyncSession): The database session.
            sync_id (UUID): The ID of the sync to update.
            sync_update (schemas.SyncUpdate): The sync update data.
            current_user (schemas.User): The current user.

        Returns:
        -------
            schemas.Sync: The updated sync.

        Raises:
        ------
            HTTPException: If the sync is not found.
        
backend/airweave/core/sync_service.py