SelectedActivity bug fix