The justiciarship originated in the king’s need for a responsible subordinate who could take a wide view of the affairs of the kingdom, act as regent when the king was abroad, and on other occasions take charge of those matters with which the king had no time to deal.
— Encyclopedia Britannica
Does the word occasions in the above sentence mean "circumstances, occurrences, or states of affairs that provide ground or reason for something" or "special events or ceremonies"?