This problem originally stems from a practice problem from my electromagnetism course, but the actual problem is not relevant for my question.
Problem
We were asked to find to solve the following LaPlace's equation with respect to $V$ (electric potential).
$$\frac{1}{R^2\sin(\theta)} \cdot \frac{d}{d\theta} \bigg(\sin(\theta) \cdot \frac{dV}{d\theta} \bigg) = 0 $$
My instructor's solution
My instructor provided us with his solution where he solves LaPlace' s equation like this:
My question
How does he go from $\sin(\theta) \frac{dV}{d\theta}=A$ to $V(\theta)=A\ln\big(\tan(\frac{\theta}{2})\big)+B$ ?
I think it something to do with dividing with $\sin(\theta)$ on both sides and then integrating with respect to $\theta$, but when I do it I get this result: $$V(\theta)=A\ln\bigg(\frac{1-\cos(\theta)}{\sin(\theta)}\bigg) $$

What you get is same -
$V(\theta)=A\ln\bigg(\frac{1-\cos\theta}{\sin\theta}\bigg)$
Now please note that
$\cos \theta = \cos^2 \frac{\theta}{2} - \sin^2 \frac{\theta}{2}$
and $\sin \theta = 2 \sin \frac{\theta}{2} \cos \frac{\theta}{2}$
So, $\frac{1-\cos\theta}{\sin\theta} = \frac{2\sin^2 \frac{\theta}{2}}{2 \sin \frac{\theta}{2} \cos \frac{\theta}{2}} = \tan \frac{\theta}{2}$
So, $V(\theta)=A\ln\bigg(\tan \frac{\theta}{2}\bigg) + B \,$ where $B$ is a constant.