Hi, First you can go to Settings and try Reset All Settings. Your Settings will reset to the factory defaults. If you It didn't work, Restore your iPhone and Be aware by doing that your Data will be destroyed So make a backup.
if non of these worked, your front camera needs a replacement and...