I followed this tutorial to upload image to my server. But it closes my app once I click on one of the pictures in my gallery. I have two buttons one to browse and the other to
I solved it. I had
android:noHistory="true"
on the same activity when I was doing login stuff and later on I changed my mind and wanted to change my architecture completely and forgot to delete that line or make it false; hence when I had the result from the gallery the activity was gone from the stack. Now I deleted it everything is like it's supposed to.