Skip to content

Commit 2fa906d

Browse files
committed
fixed previewUrl config for lumeCMS
1 parent 3ed1fe0 commit 2fa906d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

plugins/lume_cms.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,16 +53,16 @@ export function lumeCMS(userOptions: Options) {
5353
data.site = site;
5454
cms.options.data = data;
5555

56-
// Set the preview URL function
57-
cms.options.previewURL ??= function previewURL(
56+
// Set the function to return the preview URL
57+
cms.options.previewUrl ??= function previewUrl(
5858
path: string,
5959
data: unknown,
6060
hasChanged?: boolean,
6161
): undefined | string | Promise<string | undefined> {
6262
if (hasChanged) {
6363
return new Promise((resolve) => {
6464
site.addEventListener("idle", () => {
65-
resolve(previewURL(path, data));
65+
resolve(previewUrl(path, data));
6666
}, { once: true });
6767
});
6868
}

0 commit comments

Comments
 (0)