AUSTIN — A Dallas-area lawmaker has successfully killed a bill that LGBTQ rights advocates said would have perpetuated anti-gay discrimination.

Hours before a key deadline, Rep. Julie Johnson used a legislative maneuver known as a "point of order" to bump the bill from the debate calendar. It's now effectively dead after a critical legislative deadline at midnight Thursday.

Johnson, D-Carrollton, said it was "an honor to be fighting this fight" and torpedo what she called "a very hurtful piece of legislation."

"Hopefully this is the day discrimination against the LGBT community dies in the Texas House," Johnson said. "I feel great. ... I'm going to go celebrate."

House Bill 3172 has alternately been called the "Save Chick-fil-A" bill and the "most extreme anti-LGBT" legislation this year. Authored by Fort Worth GOP Rep. Matt Krause, it would have prohibited the government from taking any "adverse action" against someone for their "membership in, affiliation with, or contribution, donation or other support" to a religious organization.

The bill's supporters said it would have helped avoid the situation faced by fast-food chain Chick-fil-A, which was boycotted and booted from San Antonio's airport for making donations to Christian organizations that oppose expanded LGBTQ rights.

Lesbian, gay, bisexual and transgender advocates said the legislation would have given Texans a license to discriminate against people based on their gender identity or sexual orientation.

Krause hinted that he would try to find a way to revive the bill. House lawmakers can still debate and pass Senate bills, and anyone can attempt to amend a bill to add similar language.

"It's a shame we didn't have a chance to have this important conversation tonight. But maybe there are other ways to have that conversation," Krause said. "We'll try to find other ways to do that this session."

Krause's bill, as originally filed, was much broader; it would have protected Texans for exercising their "sincerely held religious belief or moral conviction, including beliefs or convictions regarding marriage." But he made big changes during the committee process, hoping to bring some Democrats on board.

Rejecting its comparison to the now infamous Texas bathroom bill, Krause had defended his legislation as a means to protect religious Texans from attack.

"I don't care if you're Chick-fil-A or Ben & Jerry's," Krause said earlier Thursday. "Anybody would want to make sure the government can't take any adverse action for who you associate with."

Johnson said she and her colleagues in the newly formed Texas House LGBTQ Caucus worked hard to formulate different ways to kill the bill once they realized it had a good chance of being debated by Thursday, the deadline for representatives to pass House bills and resolutions.

First, she offered a point of order arguing the amended bill improperly expanded its scope. That was shot down. Then, Johnson said an analysis of the bill's effects was inaccurate. That point of order was valid, parliamentarians said.

As the bill died, a handful of lawmakers cheered its demise. Somewhere on the House floor, someone played a recording of "Taps."

Johnson, a freshman lawmaker, ousted Irving Republican Matt Rinaldi last year. She tapped into her experience as an attorney Thursday, Johnson said, but added that while she brought the successful point of order, killing the bill was a "group effort."

"It was an honor to be chosen to be the messenger," Johnson said. "The LGBTQ Caucus is in the House. We're getting things done and we're here to stay."

In 2017, state lawmakers debated the so-called bathroom bill, which would have restricted restroom use by transgender Texas. That bill, which big businesses called discriminatory and bad for Texas business, failed to become law. Several similar bills were filed this year but have failed to get traction.

Still, state and national LGBT rights groups have opposed dozens of other bills, including a handful that are still making their way through the Senate. The legislative session ends May 27.