MCPcopy Index your code
hub / github.com/CapSoftware/Cap / getDurationTolerance

Function getDurationTolerance

apps/web/workflows/edit-video.ts:72–75  ·  view source on GitHub ↗
(duration: number)

Source from the content-addressed store, hash-verified

70}
71
72function getDurationTolerance(duration: number) {
73 if (!Number.isFinite(duration) || duration <= 0) return 0.5;
74 return Math.max(0.5, Math.min(5, duration * 0.01));
75}
76
77function isDurationClose(actual: number, expected: number) {
78 return (

Callers 1

isDurationCloseFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected