Let $N$ be a prime and let $\mathbb{T} \subset \mathrm{End}(J_0(N))$ be the Hecke algebra generated over $\mathbb{Z}$ by $U_N$ and the operators $T_p$ for primes $p \nmid N$. Fix a maximal ideal $\mathfrak{m} \subset \mathbb{T}$ and let $\mathbb{T}_{\mathfrak{m}}$ be the completion of $\mathbb{T}$ at $\mathfrak{m}$.
In the paper "Modular curves and the Eisenstein ideal" Mazur proves (Lemma II.15.1) that "multiplicity one" at $\mathfrak{m}$, i.e., $\mathrm{dim}_{\mathbb{T}/\mathfrak{m}}(J_0(N)[\mathfrak{m}](\overline{\mathbb{Q}})) = 2$, implies that the ring $\mathbb{T}_{\mathfrak{m}}$ is Gorenstein. Are there known examples where the converse implication fails, i.e., where $\mathbb{T}_{\mathfrak{m}}$ is Gorenstein but $\mathrm{dim}_{\mathbb{T}/\mathfrak{m}}(J_0(N)[\mathfrak{m}](\overline{\mathbb{Q}})) \neq 2$? (Or does the converse perhaps hold?) What about the analogous question in the case when $N$ is not necessarily prime (but, say, $\mathfrak{m}$ is "new")?