fix bug on api_calendar