After falling 6-5 down, Djokovic reacted angry by hitting the ball to the back of the court.
In a surprise for everyone, the ball hit the lineswoman and she collapsed.
After a long chat with the tournament officials, Djokovic was disqualified.
Speaking to Amazon Prime Tim Henman said: “It is right decision.
“It had a previous situation in 1995. We were ahead two sets in the doubles. I hit a ball-girl by mistake in the ear.
“Djokovic did not aim for the line judge, but he must be responsible for his actions.
“This is the only possible result.”
Novak Djokovic’s shocking exit means there will be a a Grand Slam champion this year.
Davis Cup Captain Leon Smith added: “I was shocked that he was not warned for the first one earlier.
“He has to be more consistent, if hitting ball with that much power and requires a warning.
“The second one was dangerous and it proved me right.”
Novak Djokovic remains the men’s World No.1 tennis player for now.