updated get_events method to handle category slug