Skip to content

Commit 70c11a8

Browse files
varsillCopilot
andauthored
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent aacdffe commit 70c11a8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/ex_hls/client/live/reader.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,7 @@ defmodule ExHLS.Client.Live.Reader do
445445
with tden_tag when tden_tag != nil <- chunk.metadata[:tden_tag],
446446
duration when duration != nil <- state.current_segment_duration,
447447
{:ok, datetime} <- NaiveDateTime.from_iso8601(tden_tag) do
448-
adjusted = NaiveDateTime.add(datetime, trunc(duration * 1000), :millisecond)
448+
adjusted = NaiveDateTime.add(datetime, round(duration * 1000), :millisecond)
449449
%{chunk | metadata: Map.put(chunk.metadata, :tden_tag, NaiveDateTime.to_iso8601(adjusted))}
450450
else
451451
_other ->

0 commit comments

Comments
 (0)