mirror of
https://github.com/blakeblackshear/frigate.git
synced 2025-01-02 00:07:11 +01:00
Fix crash when consecutive underscores are used in camera name (#15257)
This commit is contained in:
parent
2207a91f7b
commit
d25ffdb292
@ -62,6 +62,7 @@ function Live() {
|
|||||||
if (selectedCameraName) {
|
if (selectedCameraName) {
|
||||||
const capitalized = selectedCameraName
|
const capitalized = selectedCameraName
|
||||||
.split("_")
|
.split("_")
|
||||||
|
.filter((text) => text)
|
||||||
.map((text) => text[0].toUpperCase() + text.substring(1));
|
.map((text) => text[0].toUpperCase() + text.substring(1));
|
||||||
document.title = `${capitalized.join(" ")} - Live - Frigate`;
|
document.title = `${capitalized.join(" ")} - Live - Frigate`;
|
||||||
} else if (cameraGroup && cameraGroup != "default") {
|
} else if (cameraGroup && cameraGroup != "default") {
|
||||||
|
Loading…
Reference in New Issue
Block a user