code: def check_sync(self):
          
          # If refresh interval is not specified, we should refresh every time.
          expiration = utcnow()
          refresh_td = current_app.config.get('GITHUB_REFRESH_TIMEDELTA')
          if refresh_td:
              expiration -= refresh_td
          last_sync = parse_timestamp(self.account.extra_data['last_sync'])
          return last_sync < expiration
docs: Check if sync is required based on last sync date.