Order of an elliptic curve defined over a prime field
The fact that $n_g\cdot h\cdot P=\mathcal{O}$, does not mean that the order of $P$ is $n_g\cdot h$. It means that the order of $P$ divides $n_g\cdot h$, so it could simply be $n_g$.