fix app crash on activity recreation