How can I still show the calendar template if there are no events in that category?

I’ve added custom JavaScript to filter the calendar archive for different event categories and combinations of categories. However, if I filter to a category combination that has no events matching those categories the page reverts to the default template with no calendar and a default sidebar.

How can I make it so an empty calendar is shown instead of reverting to an empty page?

For example:

Shows calendar:

Doesn’t show calendar (because there are no barrie, varsity events scheduled)

You can also use the buttons to apply some different filters to see it’s quite jarring when it switches to a blank page with no calendar and you have to use the back button to return and select a different filter.