If you write the second product as $\displaystyle \prod_{j=1}^n\frac jn$ you will get the $\displaystyle \frac 1n$ because it doesn't depend on $\displaystyle i$.
When you bring the $\displaystyle \frac{1}{n^2}$ in, wouldn't you get -$\displaystyle \frac{1}{n^2}$ $\displaystyle \sum_{i=1}^n$ln$\displaystyle \frac{i}{n}$ ? How did the $\displaystyle \frac{1}{n}$ vanish?