It shouldn't be happening but have you tried if there is any other app active and using the camera? Probably a video calling app? If you still experiencing this issue, please help us with the following information:
OS and app name and version.
Device information, make and model.
If your aren't experiencing the issue again, let us know how you fixed the issue so the other user may benefit from your findings.