Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
oscarotero committed Oct 29, 2024
1 parent 6c968c9 commit eff002d
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions plugins/vento.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import type Site from "../core/site.ts";
import type { Data } from "../core/file.ts";
import type { Engine, Helper, HelperOptions } from "../core/renderer.ts";
import type FS from "../core/fs.ts";
import type { Environment, Plugin, Token, Loader } from "../deps/vento.ts";
import type { Environment, Loader, Plugin, Token } from "../deps/vento.ts";

export interface Options {
/** The list of extensions this plugin applies to */
Expand Down Expand Up @@ -79,15 +79,15 @@ class LumeLoader implements Loader {
}

resolve(from: string, file: string): string {
if (file.startsWith(".")) {
return normalizePath(posix.join(posix.dirname(from), file));
}
if (file.startsWith(this.#root)) {
return normalizePath(file);
}
return normalizePath(posix.join(this.#root, file));
if (file.startsWith(".")) {
return normalizePath(posix.join(posix.dirname(from), file));
}

if (file.startsWith(this.#root)) {
return normalizePath(file);
}

return normalizePath(posix.join(this.#root, file));
}
}

Expand Down

0 comments on commit eff002d

Please sign in to comment.