Skip to content

Commit 923e36d

Browse files
committed
fix format and removed file at #652
1 parent 328d17c commit 923e36d

File tree

5 files changed

+8
-7
lines changed

5 files changed

+8
-7
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ Go to the `v1` branch to see the changelog of Lume 1.
4040
- `cms.ts` file.
4141

4242
### Fixed
43-
- Escape the `%` character in the URI.
43+
- Escape the `%` character in the URI [#652].
4444
- Updated deps: `std`, `liquidjs`, `preact`, `tailwindcss`, `xml`, `postcss`, `autoprefixer`, `unocss`, `terser`, `eta`, `lightningcss`, `markdown-it-attrs`, `decap-server`.
4545
- Remove empty directories in `dest` folder.
4646
- Watcher new files on Windows.
@@ -500,6 +500,7 @@ Go to the `v1` branch to see the changelog of Lume 1.
500500
[#647]: https://github.com/lumeland/lume/issues/647
501501
[#649]: https://github.com/lumeland/lume/issues/649
502502
[#651]: https://github.com/lumeland/lume/issues/651
503+
[#652]: https://github.com/lumeland/lume/issues/652
503504

504505
[Unreleased]: https://github.com/lumeland/lume/compare/v2.2.4...HEAD
505506
[2.2.4]: https://github.com/lumeland/lume/compare/v2.2.3...v2.2.4

core/file.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ export class Page<D extends Data = Data> {
7979
get outputPath(): string {
8080
const url = this.data.url;
8181
const outputPath = url.endsWith("/") ? url + "index.html" : url;
82-
return decodeURIComponentSafe(outputPath)
82+
return decodeURIComponentSafe(outputPath);
8383
}
8484

8585
/** Returns the source path of this page */

core/server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ export async function serveFile(
129129
request: Request,
130130
): Promise<Response> {
131131
const url = new URL(request.url);
132-
const pathname = decodeURIComponentSafe(url.pathname)
132+
const pathname = decodeURIComponentSafe(url.pathname);
133133
const path = posix.join(root, pathname);
134134

135135
try {

core/utils/path.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,6 @@ export function resolveInclude(
102102
/**
103103
* decodeURI() can't decode the `%` character, as it is used in any encoded character
104104
*/
105-
export function decodeURIComponentSafe(path: string): string{
106-
return decodeURIComponent(path.replace(/%(?![0-9a-fA-F]+)/g, '%25'));
107-
}
105+
export function decodeURIComponentSafe(path: string): string {
106+
return decodeURIComponent(path.replace(/%(?![0-9a-fA-F]+)/g, "%25"));
107+
}

tests/assets/symlinks/src/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
../index_link.md
1+
../index_link.md

0 commit comments

Comments
 (0)