Evaluate $$L=\lim _{x \to 0}\left(\frac{e^x}{e^x-1}-\frac{1}{x}\right)$$ I tried in two methods
Method $1$. $$L=\lim_{x \to 0}\left(\frac{\frac{e^x}{x}}{\frac{e^x-1}{x}}-\frac{1}{x}\right)$$
But $$\lim_{x \to 0}\frac{e^x-1}{x}=1$$ So
$$L=\lim_{x \to 0}\left(\frac{e^x}{x}-\frac{1}{x}\right)=\lim_{x \to 0}\frac{e^x-1}{x}=1$$
Method $2$. By taking LCM we get
$$L=\lim_{x \to 0}\frac{xe^x-e^x+1}{xe^x-x}$$ Since the limit is in $\frac{0}{0}$ form using L'Hopital's Rule twice we get
$$L=\lim_{x \to 0}\frac{xe^x}{xe^x+e^x-1}$$ i.e.,
$$L=\lim_{x \to 0}\frac{xe^x+e^x}{xe^x+2e^x}=\frac{1}{2}$$
I am sure that second method is correct, but i want to know whats is wrong in first method