After taking a video, I want to add it to an album and keep its asset id for later use
let asset = await MediaLibrary.createAssetAsync(videoUri);
console.log(asset.id); // 7492, for example
let assets = ;
// given an album
await MediaLibrary.addAssetsToAlbumAsync(assets, album, false);
// now try to retrieve it
let assetInfo = await MediaLibrary.getAssetInfoAsync(asset.id);
// null, not found
But, when I fetch the list of assets in the album using MediaLibrary.getAssetsAsync, I find the video is in the album with an asset id of 7493 (for example). The id has been incremented by 1.
Is this expected behavior? Is there a definitive way to get the actual asset id for an item that has just been added to an album?