State lawmakers approved a measure Monday to avoid a government shutdown during the budget impasse.

They voted to extend last year's budget until May 31, which Gov. Andrew Cuomo issued as an alternative plan to keep the government operating.

The State Senate and Assembly approved the measure.

This comes after lawmakers failed to meet the April 1 deadline to pass a spending plan for the new fiscal year.

"Passing this extender isn't a punt of our duties. It's just trying to make sure that the government isn’t shut down, and people who work hard for the State of New York, school districts, and hospitals can continue to do the Godly work that they do," Assembly Speaker Carl Heastie said.

Lawmakers have said they are still negotiating on a larger budget and hope to have a plan in the next couple of days, but they have been saying that since early last week.

Lawmakers were exhausted and frustrated that they couldn't reach a deal, and some are asking why there were policy items in the budget, instead of just funding bills to keep the state running.

Most notably, state leaders had difficulty reaching agreement on raising the age of criminal liability to 18, which the governor wanted as part of the budget bill.

"I think this was a year when there was a lot of policy in the budget. When you have a lot of policy in the budget, it's attempting to do that on top of the normal budget items," Heastie said. "So this is probably a little more challenging."

Lawmakers are expected to remain in town at least until Wednesday.