Texas church apologizes for 'unauthorized' 'Hamilton' play comparing being gay to drug addiction

A church in Texas is apologizing "for staging an unauthorized production of Hamilton" and has agreed to "pay damages for our actions."

The apology was issued Tuesday by The Door Christian Fellowship Ministries in McAllen, Texas, nearly three weeks after the church produced and livestreamed a rendition of the Tony Award-winning musical “Hamilton.” The production appeared to implement script changes to include religious references and concluded with a sermon by a pastor comparing being gay to being addicted to alcohol or drugs.

The unsigned statement was written in first-person as the church's pastor, Roman Gutierrez.

"On behalf of The Door Christian Fellowship McAllen Church, I would like to personally apologize to the creator of Hamilton, Lin-Manuel Miranda, the producers of Hamilton, and the numerous others who contributed their intellectual property to Hamilton, for staging an unauthorized production of Hamilton that infringed on the rights and copyrights of many," the statement posted on the church's Instagram account read.

The statement also clarified that the church did not request or receive a license from the producers or creators of the official “Hamilton” production to stage, replicate or alter any part of the show — a crucial step to avoid copyright infringement.

"We respect the copyrights of Hamilton’s author and contributors," the statement said. "We acknowledge there are lawful avenues to obtain a license to stage properties which we did not pursue. And it is never permissible to alter an artistic work such as Hamilton without legal permission."

The church said it also did not seek "prior permission to alter Lin-Manuel Miranda’s work by changing the music, the lyrics, deleting songs, and adding dialogue."

Two weeks ago, Miranda expressed his gratitude to "all of you who reached out about this illegal, unauthorized production," the "Hamilton" creator said. "Now lawyers do their work.”

Following the backlash, the church has agreed to never stage a performance of "Hamilton" again and to destroy all recordings and images of the unauthorized performances as well as its rehearsals, according to the statement.

"Lastly, we will pay damages for our actions," the church said without specifying the amount.

Representatives for Miranda and the official “Hamilton” production on Broadway told NBC News on Wednesday that all damages paid by the church will be donated to the South Texas Equality Project, a coalition of organizations that support and advocate for the LGBTQ community in the Rio Grande Valley.

The livestream video of the unauthorized version of the play that the church staged the weekend of Aug. 6 has been taken down, but NBC News obtained a recording of the performance from writer and atheism advocate Hemant Mehta. Mehta would not identify whom he obtained the video from.

Associate pastor Victor Lopez can be heard comparing homosexuality to drug addiction in the final sermon added by the church, according to a full video of the performance.

“Maybe you struggle with alcohol, with drugs, homosexuality, maybe you struggle with other things in life, your finances, whatever, relationships,” the video shows Lopez say. “God can help you tonight.”

The “Hamilton” version staged by the church also included several biblical references that were not originally in the musical, according to a description of the livestream by Howard Sherman, the director of the Arts Integrity Initiative at The New School in New York City, who was not affiliated with the performance.

Sherman said the production, which was first reported on by OnStage Blog, changed one of the main characters’ lines by adding the sentence, “Jesus gives me the strength to pull through; when I needed him most he was right on time.”

Another line from a video posted by Mehta shows the actor portraying Alexander Hamilton reciting more changed lyrics.

“What is a legacy?” the actor says. “It’s knowing that you repented and accepted the gospel of Jesus Christ that sets men free. You sent your sinless son of man on Calvary to die for me.”

In the church's statement, Gutierrez appeared to "recognize as the Pastor of the church that I have an obligation and responsibility to follow the law and educate our community about these protocols."

"Our ministry will use this moment as a learning opportunity about protected artistic works and intellectual property," the statement read.

Follow NBC Latino on Facebook, Twitter and Instagram.