Fixed resource logic to load calendar events properly.