My Nexus 5 camera is not working properly

I have Google Nexus 5, whenever I click pictures I have to face a relatively longer shutter lag and the auto focus has also become slow as a result I can’t capture things even in a little motion. Is it Nexus i.e. Company’s problem or is there something wrong with my phone? Should I update it or is it something related to the hardware?
