The activity in the manifest is singleTask. The onNewIntent method is called when the activity is called again. I do intialize the Textviews and other views in my onCreate but sometimes the app crashes in onNewIntent where I do not initialize any variables and directly use the method of that view. For eg, setText method of TextView. Sometimes it throws NullPointerException and do not know why does it do so. In other screen where I have done the same thing it never does that.
Do I need to instantiate the variables again in onNewIntent?