Skip to content

Commit 685d902

Browse files
committed
fix: follow-up to prev commit
1 parent eea6d43 commit 685d902

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

apps/web/src/sounds/sounds-store.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { storageService } from "@/services/storage/service";
44
import { toast } from "sonner";
55
import { EditorCore } from "@/core";
66
import { buildLibraryAudioElement } from "@/timeline/element-utils";
7+
import { mediaTimeFromSeconds } from "@/wasm";
78

89
interface SoundsStore {
910
topSoundEffects: SoundEffect[];
@@ -227,7 +228,7 @@ export const useSoundsStore = create<SoundsStore>((set, get) => ({
227228
const element = buildLibraryAudioElement({
228229
sourceUrl: audioUrl,
229230
name: sound.name,
230-
duration: sound.duration,
231+
duration: mediaTimeFromSeconds({ seconds: sound.duration }),
231232
startTime: currentTime,
232233
buffer,
233234
});

0 commit comments

Comments
 (0)