Whether you like it or not, Buffalo Wild Wings is winning with boneless chicken wings.

The chain's popular Tuesday "buy one, get one free" deal on traditional bone-in wings has been a big draw for Buffalo Wild Wings' customers, but it was eating into the company's bottom line. Costs for traditional wings have spiked, rising more than 25% in the past year.

So Wild Wings decided to switch the Tuesday deal to lower-cost boneless wings as a savings measure.

Customers weren't necessarily digging the move: sales at restaurants that were open at the same time last year fell more than 2% after the change. But it made good business sense, since Buffalo Wild Wings was able to find some important savings.

That's why the company says the boneless wings are here to stay, at least for now.

"The recent Tuesday promotion shift from traditional to boneless wings at company-owned restaurants will continue to improve cost of sales while traditional wing prices remain elevated," CEO Sally Smith said in a prepared statement on Tuesday.

Overall, the company's profit continued its downward slide. Earnings fell 20% from the same quarter in 2016, mostly because customers still have a strong taste for chicken wings with bones in them.

Investors were expecting that. Actually, Wall Street analysts' forecasts were far too pessimistic. The restaurant chain's profit smashed expectations. Investors also cheered Buffalo Wild Wings raising its financial outlook for the rest of the year.

Shares of Buffalo Wild Wings (BWLD) surged 18% on Wednesday.

Related: Chipotle's profit ravaged by hurricanes, hack and high avocado prices

Still, it has been a rocky year for the company. Its stock is down 23% this year due to slumping sales and profit and an activist investor campaign from a group that wanted to reshape the chain. Smith announced over the summer that she would step down after 21 years as CEO.

Like many other retailers and restaurants, Wild Wings weathered the impact from Hurricanes Harvey and Irma during the quarter. It was forced to close 71 restaurants because of the storms, costing the company nearly $3 million in sales.

One particularly good sign: Declining NFL ratings aren't hitting Wild Wings so far. The company said on an conference call with investors that it doesn't expect the viewership drop to hurt sales.