  When Type Ia supernovae are used to infer cosmological parameters, their
luminosities are compared to those from a homogeneous cosmology. In this note
we propose a test to examine to what degree SN Ia have been observed on lines
of sight where the average matter density is \textit{not} representative of the
homogeneous background. We apply our test to the Pantheon SN Ia compilation,
and find two redshift bins which indicate a moderate bias to over-density at
$\sim 2\sigma$. We modify the Tripp estimator to explicitly de-lens SN Ia
magnitudes, and show that this reduces scatter of Hubble diagram residuals.
Using our revised Tripp estimator, the effect on cosmological parameters from
Pantheon in $\Lambda$CDM is however small with a change in mean value from
$\Omega_{\rm m} = 0.317 \pm 0.027$ (baseline) to $\Omega_{\rm m} = 0.312 \pm
0.025$ (de-lensed). For the Flat $w$CDM case it is $\Omega_{\rm m} = 0.332 \pm
0.049$ and $w = -1.16 \pm 0.16$ (baseline) versus $\Omega_{\rm m} = 0.316 \pm
0.048$ and $w = -1.12 \pm 0.15$ (de-lensed). We note that the effect of lensing
on cosmological parameters may be larger for future high-z surveys.
