- updated version for optional activity passing