статус входа в google api изменяется после обновления - PullRequest
0 голосов
/ 30 сентября 2019

Статус входа изменился после обновления, и я хочу получить данные календаря Google после входа в систему

componentDidMount() {

  const { fetchGoogleMeeting } = this.props;

  ApiCalendar.onLoad(() => {

    if (ApiCalendar.sign)
      return ApiCalendar.gapi.client.calendar.events
        .list({
          calendarId: "primary",

          showDeleted: false,
          singleEvents: true,

          orderBy: "startTime"
        })
        .then(res => {
          console.log(res, "iiii");
          fetchGoogleMeeting(res.result.items);
        });
  });
}
...