This commit is contained in:
Timothy J. Baek
2024-09-29 23:08:55 +02:00
parent 677c36c3aa
commit 6afc686e17
6 changed files with 22 additions and 10 deletions

View File

@@ -889,5 +889,6 @@ export const formatFileSize = (size) => {
};
export const getLineCount = (text) => {
return text.split('\n').length;
console.log(typeof text);
return text ? text.split('\n').length : 0;
};