Skip to content

Commit

Permalink
fix(CR-259): clipFrom and seekTo must be int (#909)
Browse files Browse the repository at this point in the history
### Description of the Changes

Please add a detailed description of the change, whether it's an
enhancement or a bugfix.
If the PR is related to an open issue please link to it.

**Issue:**

**Fix:**

#### Resolves FEC-[Please add the ticket reference here]
  • Loading branch information
MosheMaorKaltura authored Jan 24, 2025
1 parent 936533d commit ba45f00
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/common/utils/kaltura-params.ts
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,10 @@ function addStartAndEndTime(url: string, sources: PKSourcesConfigObject): string
const seekFrom = Utils.Object.getPropertyPath(sources, 'seekFrom');
const clipTo = Utils.Object.getPropertyPath(sources, 'clipTo');
if (typeof seekFrom === 'number' && url.indexOf(SEEK_FROM) === -1) {
url += getQueryStringParamDelimiter(url) + SEEK_FROM + seekFrom * 1000;
url += getQueryStringParamDelimiter(url) + SEEK_FROM + Math.floor(seekFrom * 1000);
}
if (typeof clipTo === 'number' && url.indexOf(CLIP_TO) === -1) {
url += getQueryStringParamDelimiter(url) + CLIP_TO + clipTo * 1000;
url += getQueryStringParamDelimiter(url) + CLIP_TO + Math.floor(clipTo * 1000);
}
return url;
}
Expand Down

0 comments on commit ba45f00

Please sign in to comment.