restoring mainActivity