Western New York didn’t get clobbered by Superstorm Sandy, for which we are grateful. We should also be grateful that officials were prepared, just in case.

From the county and city levels down to the smallest towns and villages, officials here had a plan. As Buffalo Mayor Byron W. Brown said, much of that planning resulted from the October Surprise storm in 2006. The public was alerted and emergency operations centers were in operation by Sunday. Planning went so far as considering whether to postpone Halloween trick-or-treating.

The storm devastated the Eastern Seaboard, costing dozens of lives and paralyzing parts of New York City.

And now, with the storm passed, Western New Yorkers are rallying to the aid of their downstate neighbors. More than 140 firefighters, Red Cross volunteers and members of the Air National Guard have put their lives on hold to help others.

Gov. Andrew M. Cuomo, along with other governors, declared a state of emergency well in advance of the storm, helping to mitigate some of the impact.

Cuomo is also looking ahead, suggesting a levee system or storm surge barriers and encouraging the state to face up to the threat of rising sea levels and weather extremes brought on by climate change. It’s worth noting that a 2010 report, “New York State Sea Level Rise Task Force Report to the Legislature,” raised the possibility of the type of destruction caused by Sandy. That report should be re-examined.

In addition to the value of preparation, Sandy also showed that only the federal government has the ability to fully respond to such a widespread catastrophe. With climate change making extreme weather events more likely, it would be dangerous to hamstring the Federal Emergency Management Agency. Yet that is apparently just what Republican Mitt Romney would do. In June 2011, he supported the idea of curtailing federal disaster response. “Absolutely. Every time you have an occasion to take something from the federal government and send it back to the states, that’s the right direction,” he said. “And if you can go even further and send it back to the private sector, that’s even better.”

The result of such a move would have been disastrous for the millions of victims of Sandy.

President Obama’s budget would cut FEMA funding by 3 percent for 2013, with the Disaster Relief Fund seeing the largest cutback, while increasing funding for state and local programs and flood insurance. Romney’s promise of drastic cuts to discretionary spending would almost certainly force the gutting of FEMA.

Obama sees the federal government doing more in disasters. Romney, not so much. The Republican candidate has, in the past, agreed with those who suggested FEMA could be dissolved as part of budget cuts. Lately his aides are insisting that he would not abolish the agency.

The candidate’s disdain for big government in this case is sorely misplaced. There is only so much that governors and mayors can do. Romney ought to know this well. As Massachusetts governor, he requested federal disaster assistance for storm cleanup.

Local and state officials understand that one of the true tests of leadership comes during a disaster. Here and downstate, they appear to have risen to that challenge. But it would not be possible without the assurance of federal assistance.