In my React Native application I am using React Native Video.
Currently, the library offers caching (using SPTPersistentCache and DVAssetLoaderDelegate). The caching currently implemented is by the asset's URL. Or in other words, if I watch a video from https://video.net/video.mp4 next time I pass the same link to React Native Video, the cached version of the file will be loaded.
However, in my application the same video file can be stored in different places (it will have different download links). Thus, caching would not work properly for me and it might result in an already cached file being re-downloaded once again if its download link is different.
Is there a way I could cache files by a unique ID rather than their download link. All my video files have unique IDs and I would like to cache them by their ID.
Any help would be appreciated.