fix for context cast to activity