My LG L5ii is having the same problem, the camera is rotating on wrong orientation. When it's supposed to be potrait it kept being landscape and vice versa. I had deleted caches and rebooted as suggested here, but nothing changed. So i did factory reset and it worked :'(:'(:'(:'(