initialize method

Future<void> initialize()

Initialize cache by loading values from storage

Implementation

Future<void> initialize() async {
  if (_initialized) return;

  final cookie = await getCSRFCookie();
  if (cookie != null) {
    _csrfToken = _extractCSRFTokenFromCookie(cookie);
  }

  _initialized = true;
}