Commit
β’
c379e82
1
Parent(s):
652223b
π Fix page switching
Browse files
src/lib/utils/upperFirst.ts
CHANGED
@@ -1,3 +1,6 @@
|
|
1 |
export function upperFirst(s: string): string {
|
|
|
|
|
|
|
2 |
return s[0].toLocaleUpperCase() + s.slice(1);
|
3 |
}
|
|
|
1 |
export function upperFirst(s: string): string {
|
2 |
+
if (!s) {
|
3 |
+
return s;
|
4 |
+
}
|
5 |
return s[0].toLocaleUpperCase() + s.slice(1);
|
6 |
}
|