Skip to content

Commit

Permalink
feat: fix bug with showing NaN views when there's no views on a video
Browse files Browse the repository at this point in the history
  • Loading branch information
SudharakaP committed Jan 16, 2025
1 parent 7ad5873 commit b57f44c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/renderer/helpers/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -599,7 +599,7 @@ export async function getPicturesPath() {

export function extractNumberFromString(str) {
if (typeof str === 'string') {
return parseInt(str.replaceAll(/\D+/g, ''))
return parseInt(str.replaceAll(/\D+/g, '')) || 0
} else {
return NaN
}
Expand Down

0 comments on commit b57f44c

Please sign in to comment.