roflcoopter / viseron

Self-hosted, local only NVR and AI Computer Vision software. With features such as object detection, motion detection, face recognition and more, it gives you the power to keep an eye on your home, office or any other place you want to monitor.
MIT License
1.76k stars 179 forks source link

[Regression V2] Doubled camera name in recording URLs #427

Closed ConstBur closed 1 year ago

ConstBur commented 1 year ago

The URLs of the recordings in the frontend contain /camera_name twice, e.g. /recordings/garage/garage/2022-12-14/2022-12-14_22:10:48.mp4.

I'd guess the problem is here: https://github.com/roflcoopter/viseron/blob/dev/frontend/src/components/videoplayer/VideoPlayer.tsx#L56

If you'd like to make a quick and dirty fix on the frontend side, you could pass the camera name to the component and do something like this:

content: recording.filename.split(".")[0].replace(`/${camera_name}`, "")
roflcoopter commented 1 year ago

Thanks for the report!

However, i am not seeing this issue, could you explain a bit more where this occurs? If i copy the link from a recording and open it directly in the browser it looks like this: https://my_domain.com/recordings/doorbell/2022-12-17/12:55:12.mov

ConstBur commented 1 year ago

Figured out why it happens: in my recorder config I put the folder as /recordings/garage and didn't realize Viseron was appending the camera name. I guess it would be a nice addition to the docs :)