Added camera signup for takePicture in onPostResume function to fix the bug