Fix bug DNN-3608: use GetEffectivePortalId to get correct portal id.