interface CommonJSModuleRecord { $require(id: string, mod: any): any; children: CommonJSModuleRecord[]; exports: any; id: string; loaded: boolean; parent: undefined; path: string; paths: string[]; require: typeof require; } $getter; export function main() { return $requireMap.$get(Bun.main); } export function require(this: CommonJSModuleRecord, id: string) { const existing = $requireMap.$get(id) || $requireMap.$get((id = $resolveSync(id, this.path, false))); if (existing) { // Scenario where this is necessary: // // In an ES Module, we have: // // import "react-dom/server" // import "react" // // Synchronously, the "react" import is created first, and then the // "react-dom/server" import is created. Then, at ES Module link time, they // are evaluated. The "react-dom/server" import is evaluated first, and // require("react") was previously created as an ESM module, so we wait // for the ESM module to load // // ...and then when this code is reached, unless // we evaluate it "early", we'll get an empty object instead of the module // exports. // $evaluateCommonJSModule(existing); return existing.exports; } if (id.endsWith(".json") || id.endsWith(".toml") || id.endsWith(".node")) { return $internalRequire(id); } // To handle import/export cycles, we need to create a module object and put // it into the map before we import it. const mod = $createCommonJSModule(id, {}, false); $requireMap.$set(id, mod); // This is where we load the module. We will see if Module._load and // Module._compile are actually important for compatibility. // // Note: we do not need to wrap this in a try/catch, if it throws the C++ code will // clear the module from the map. // var out = this.$require(id, mod); // -1 means we need to lookup the module from the ESM registry. if (out === -1) { try { out = $requireESM(id); } catch (exception) { // Since the ESM code is mostly JS, we need to handle exceptions here. $requireMap.$delete(id); throw exception; } const esm = Loader.registry.$get(id); // If we can pull out a ModuleNamespaceObject, let's do it. if (esm?.evaluated && (esm.state ?? 0) >= $ModuleReady) { const namespace = Loader.getModuleNamespaceObject(esm!.module); return (mod.exports = // if they choose a module namespace.__esModule ? namespace : Object.create(namespace, { __esModule: { value: true } })); } } $evaluateCommonJSModule(mod); return mod.exports; } export function requireResolve(this: string | { path: string }, id: string) { return $resolveSync(id, typeof this === "string" ? this : this?.path, false); } export function requireNativeModule(id: string) { // There might be a race condition here? let esm = Loader.registry.$get(id); if (esm?.evaluated && (esm.state ?? 0) >= $ModuleReady) { const exports = Loader.getModuleNamespaceObject(esm.module); return exports.default; } return $requireESM(id).default; } b9&showmsg=1&follow=1'>webdav/internal/xml/read.go (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2018-02-07Strip invalid XML characters to avoid parsing errorsGravatar Frédéric Guillot 1-1/+26
2018-02-07Remove period for feed errorsGravatar Frédéric Guillot 4-23/+23
2018-02-07Improve error handling when the response is emptyGravatar Frédéric Guillot 5-6/+28
2018-02-07Add missing French translationGravatar stratmaster 2-2/+4
2018-02-05Update ChangeLog2.0.2Gravatar Frédéric Guillot 1-0/+14
2018-02-04Add support for Let's Encrypt http-01 challengeGravatar Frédéric Guillot 32-286/+2042
2018-02-04Move template functions outside engine (refactoring)Gravatar Frédéric Guillot 9-214/+254
2018-02-04Take timezone into consideration when calculating relative timeGravatar Frédéric Guillot 16-58/+91
2018-02-03Add support for HTTP Strict Transport Security headerGravatar Frédéric Guillot 4-3/+33
2018-02-03Add support for base URLs with subfoldersGravatar Frédéric Guillot 10-23/+105
2018-02-01Update German translationGravatar stratmaster 2-4/+12
2018-01-31Add missing about menu in settingsGravatar Frédéric Guillot 5-5/+29
2018-01-31Show API URL endpoints in user interfaceGravatar Frédéric Guillot 11-14/+99
2018-01-29Do not update entry date while refreshing a feedGravatar Frédéric Guillot 1-4/+5
We do not update the published date because some feeds do not contains any date, in this case it default to time.Now(), which could change the order of items on the history page.
2018-01-29Enable debug mode for integration testsGravatar Frédéric Guillot 1-1/+1
2018-01-29Add the possiblity to enable debug mode with an environment variableGravatar Frédéric Guillot 2-1/+6
2018-01-29Keep code base tidyGravatar Frédéric Guillot 5-18/+16
2018-01-29Add flag to enable debug loggingGravatar Rogier Lommers 2-7/+64
2018-01-25Improve unread counter updatesGravatar Mahendra Kalkura 1-6/+35