"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }

var _chunk7QVYU63Ejs = require('./chunk-7QVYU63E.js');

// src/server/token.ts
async function getServerToken() {
  const { cookies } = await Promise.resolve().then(() => _interopRequireWildcard(require("next/headers")));
  const cookieStore = await cookies();
  return _optionalChain([cookieStore, 'access', _ => _.get, 'call', _2 => _2("token"), 'optionalAccess', _3 => _3.value]);
}
_chunk7QVYU63Ejs.__name.call(void 0, getServerToken, "getServerToken");



exports.getServerToken = getServerToken;
//# sourceMappingURL=chunk-YUO55Q5A.js.map