Woody Allen's battle with Amazon has ended.

The filmmaker had sued Amazon in February after the online giant ended his 2017 contract without ever releasing a completed film, "A Rainy Day in New York." Sources previously claimed the film contained an adult-teen sex scene.

Amazon had responded that Allen, whose daughter Dylan has accused him of molesting her when she was a girl, breached the 4-movie deal by making insensitive remarks about the #MeToo movement. Allen has repeatedly denied the allegations made by his daughter.

WOODY ALLEN ARCHIVE WRITINGS DETAIL HIS 'VIVID OBSESSION' WITH TEENAGE GIRLS, REPORT SAYS

Allen and Amazon agreed that the case should be dismissed without prejudice, according to papers filed Friday in U.S. District Court. Terms were not disclosed.

Actress Scarlett Johansson, star of director Woody Allen's new film

Scarlett Johansson, seen here with director Woody Allen in 2008, is being slammed by fans on social media for defending Allen even though she called out James Franco. (Reuters)

Attorney Robert Klieger told U.S. District Judge Denise Cote in April that Allen, 83, breached his contract when he made "public comments that at a minimum were insensitive to the #MeToo movement."

Klieger said that Allen's remarks hurt the project, which starred Timothée Chalamet, Selena Gomez, Elle Fanning, Jude Law and Rebecca Hall, and made the film too difficult to promote.

RONAN FARROW DEFENDS SISTER DYLAN, MOTHER MIA FROM BROTHER MOSES' ABUSE CLAIMS

Allen did not attend the April hearing; his lawyer, John Quinn, told the judge that Amazon initially claimed it was ending the deal because of sexual abuse allegations made against Allen, not because of his incendiary remarks.

Director Woody Allen speaks on stage at the 2017 American Film Institute Life Achievement Award Show in Los Angeles, California, U.S., June 8, 2017.

Many actors have distanced themselves from director Woody Allen. (Reuters)

"A Rainy Day in New York" was released overseas, but not in the U.S. Allen's career has slowed in recent years, with several actors who had appeared in his films saying they would not work with him again.

The Associated Press contributed to this report.