added a try catch to getlastchar function

This commit is contained in:
Miodec 2021-01-10 15:26:59 +00:00
parent af996d3e84
commit 0b99ccdaff

View file

@ -321,7 +321,11 @@ export function getReleasesFromGitHub() {
// }
export function getLastChar(word) {
return word.charAt(word.length - 1);
try {
return word.charAt(word.length - 1);
} catch {
return "";
}
}
export function capitalizeFirstLetter(str) {