fixed feature to upload sound files
This commit is contained in:
@@ -43,8 +43,12 @@ export function useSightingFeed(url: string | undefined) {
|
||||
}, [audioArmed, latestRef]);
|
||||
|
||||
const soundSrc = useMemo(() => {
|
||||
if (state?.sightingSound?.includes(".mp3")) {
|
||||
const file = state.soundOptions?.find((item) => item.name === state.sightingSound);
|
||||
return file?.soundUrl;
|
||||
}
|
||||
return getSoundFileURL(state?.sightingSound) ?? switchSound;
|
||||
}, [state.sightingSound]);
|
||||
}, [state.sightingSound, state.soundOptions]);
|
||||
|
||||
function refetchInterval(query: Query<SightingType, Error, SightingType, (string | undefined)[]>) {
|
||||
if (!query) return;
|
||||
|
||||
Reference in New Issue
Block a user