Skip to content

Commit

Permalink
fix: currentTime mode handling as it was marked optional, while we on…
Browse files Browse the repository at this point in the history
…ly accept one of two values
  • Loading branch information
rolandkakonyi committed Dec 13, 2023
1 parent 878d065 commit c97b8a8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/player.ts
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,9 @@ export class Player extends NativeInstance<PlayerConfig> {
*
* @param mode - The time mode to specify: an absolute UNIX timestamp ('absolute') or relative time ('relative').
*/
getCurrentTime = async (mode?: 'relative' | 'absolute'): Promise<number> => {
getCurrentTime = async (
mode: 'relative' | 'absolute' = 'absolute'
): Promise<number> => {
return PlayerModule.currentTime(this.nativeId, mode);
};

Expand Down

0 comments on commit c97b8a8

Please sign in to comment.