opennms
Version:
Client API for the OpenNMS network monitoring platform
1 lines • 4.96 kB
JSON
{"remainingRequest":"/data/node_modules/babel-loader/lib/index.js!/data/node_modules/axios/lib/helpers/cookies.js","dependencies":[{"path":"/data/node_modules/axios/lib/helpers/cookies.js","mtime":1553611387516},{"path":"/data/.babelrc","mtime":1553611371556},{"path":"/data/node_modules/cache-loader/dist/cjs.js","mtime":1553611387012},{"path":"/data/node_modules/babel-loader/lib/index.js","mtime":1553611386992}],"contextDependencies":[],"result":["'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = utils.isStandardBrowserEnv() ?\n\n// Standard browser envs support document.cookie\nfunction standardBrowserEnv() {\n return {\n write: function write(name, value, expires, path, domain, secure) {\n var cookie = [];\n cookie.push(name + '=' + encodeURIComponent(value));\n\n if (utils.isNumber(expires)) {\n cookie.push('expires=' + new Date(expires).toGMTString());\n }\n\n if (utils.isString(path)) {\n cookie.push('path=' + path);\n }\n\n if (utils.isString(domain)) {\n cookie.push('domain=' + domain);\n }\n\n if (secure === true) {\n cookie.push('secure');\n }\n\n document.cookie = cookie.join('; ');\n },\n\n read: function read(name) {\n var match = document.cookie.match(new RegExp('(^|;\\\\s*)(' + name + ')=([^;]*)'));\n return match ? decodeURIComponent(match[3]) : null;\n },\n\n remove: function remove(name) {\n this.write(name, '', Date.now() - 86400000);\n }\n };\n}() :\n\n// Non standard browser env (web workers, react-native) lack needed support.\nfunction nonStandardBrowserEnv() {\n return {\n write: function write() {},\n read: function read() {\n return null;\n },\n remove: function remove() {}\n };\n}();",{"version":3,"sources":["node_modules/axios/lib/helpers/cookies.js"],"names":["utils","require","module","exports","isStandardBrowserEnv","standardBrowserEnv","write","name","value","expires","path","domain","secure","cookie","push","encodeURIComponent","isNumber","Date","toGMTString","isString","document","join","read","match","RegExp","decodeURIComponent","remove","now","nonStandardBrowserEnv"],"mappings":"AAAA;;AAEA,IAAIA,QAAQC,QAAQ,YAAR,CAAZ;;AAEAC,OAAOC,OAAP,GACEH,MAAMI,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AO;AACLtB,WAAO,SAASA,KAAT,GAAiB,CAAE,CADrB;AAELgB,UAAM,SAASA,IAAT,GAAgB;AAAE,aAAO,IAAP;AAAc,KAFjC;AAGLI,YAAQ,SAASA,MAAT,GAAkB,CAAE;AAHvB,GAAP;AAKD,CAND,EAzCF","file":"cookies.js","sourceRoot":"/data","sourcesContent":["'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs support document.cookie\n (function standardBrowserEnv() {\n return {\n write: function write(name, value, expires, path, domain, secure) {\n var cookie = [];\n cookie.push(name + '=' + encodeURIComponent(value));\n\n if (utils.isNumber(expires)) {\n cookie.push('expires=' + new Date(expires).toGMTString());\n }\n\n if (utils.isString(path)) {\n cookie.push('path=' + path);\n }\n\n if (utils.isString(domain)) {\n cookie.push('domain=' + domain);\n }\n\n if (secure === true) {\n cookie.push('secure');\n }\n\n document.cookie = cookie.join('; ');\n },\n\n read: function read(name) {\n var match = document.cookie.match(new RegExp('(^|;\\\\s*)(' + name + ')=([^;]*)'));\n return (match ? decodeURIComponent(match[3]) : null);\n },\n\n remove: function remove(name) {\n this.write(name, '', Date.now() - 86400000);\n }\n };\n })() :\n\n // Non standard browser env (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return {\n write: function write() {},\n read: function read() { return null; },\n remove: function remove() {}\n };\n })()\n);\n"]}]}