The gynecologist found out that the girl was in need of immediate treatment