Back in February, Dick's Sporting Goods made a bold decision to stop selling assault style rifles and high capacity magazines, and to raise the minimum age to purchase a gun to 21.

Executives there braced for pain. Instead they got good news.

Dick's Sporting Goods (DKS) stock price surged by as much as 27% after it reported stronger than expected quarterly sales and profit Wednesday.

It's the first measure of their decision to pull away from some guns.

"There's been a number of people who have started shopping us, or said they're going to shop us more, because of the policy," said Chief Executive Officer Ed Stack on an earnings call with analysts Wednesday. "There's definitely been some benefit of people who joined us, so to speak, because of the policy."

Stack said on the call that the company has raised its full year 2018 guidance to a range of $2.92 to $3.12 earnings per share, from a previously announced range of $2.80 to $3.

The company also announced that its online sales jumped 24%. Same-store sales, however, were down 2.5%.

In its earnings statement, the company blamed the same-store slump on "a continued deceleration in hunt and electronics sales, as well as colder spring weather, which resulted in a delayed start to key outdoor sports and activities."

Related: Dick's expected backlash with new gun policy, but got flowers instead

Stack, and his chief financial officer, Lee Belitsky, both said the company's "hunt business" was getting dragged down by the company's new gun policy, though it was already on the decline before that.

The gun industry as a whole has experienced sharp declines in sales and profit since the 2016 election of President Trump, a Republican endorsed by the National Rifle Association. Concerns about gun control had driven sales during the Obama administration, but those concerns have dissipated since.

"Hunting business saw an accelerated decline in an area that was already challenging," said Belitsky.

While the company's new gun policy might have gained some fans among customers, it definitely turned off some friends among the gun industry. The National Shooting Sports Foundation, a gun industry group, expelled Dick's from its membership on May 4.

The NSSF said it made the move after Dick's hired a gun control lobbyist.

Related: Dick's stops selling 'assault-style' weapons

A few days later, on May 9, the gun maker Mossberg terminated its relationship with Dick's.

"We don't have the best relationship with the firearms manufacturers right now," said Stack, when asked about it by an analyst. "As far as the NSSF expelling us, we didn't have a whole lot to do with them ... It's not really that big of a deal."

Other big retailers have made changes to their gun policies since a mass shooting at a high school in Parkland, Florida, that killed 17 people.

Walmart, (WMT)which stopped selling assault-style rifles in 2015, earlier this year raised the minimum gun buying age to 21. Kroger (KR) also said it would phase out gun sales at its Fred Meyer stores.

Related: Bank of America sticks with Remington through Chapter 11

The gun and ammunition maker Vista Outdoor (VSTO)said earlier this month that it might divest from its gun brands. But under pressure from Wall Street firm BlackRock (BLK), a major shareholder, American Outdoor Brands (AOBC), which owns the Smith & Wesson brand, said it won't be pushed into "politically motivated" actions.

A top executive for Bank of America (BAC) said in April that the bank would no longer "finance military-style firearms for civilian use," though the bank continued to help Remington through its bankruptcy process, which ended earlier this month.