Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(JekyllSettings.ts): adding convertFileName to the title variable #417

Merged
merged 1 commit into from
Jan 13, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/jekyll/settings/JekyllSettings.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { O2PluginSettings } from '../../settings';
import { convertFileName } from '../../FilenameConverter';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Fix incorrect relative import path

The import path should be ../../../FilenameConverter to correctly reference the module from src/jekyll/settings/JekyllSettings.ts.

🔗 Analysis chain

Verify the FilenameConverter module path

The import looks correct, but let's verify the module path and function existence.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the existence and exports of the FilenameConverter module

# Check if the file exists relative to the current file
fd -t f "FilenameConverter.ts" src/

# Verify the function export
ast-grep --pattern 'export function convertFileName($_) {
  $$$
}'

Length of output: 129


Script:

#!/bin/bash
# Check the actual exports of FilenameConverter.ts
cat src/FilenameConverter.ts

# Alternative: Look for any export containing 'fileName' or 'filename'
ast-grep --pattern 'export $_ $$$fileName$$$'

Length of output: 346


export default class JekyllSettings implements O2PluginSettings {
private _jekyllPath: string;
Expand All @@ -9,6 +10,7 @@ export default class JekyllSettings implements O2PluginSettings {
day: string,
title: string,
): string {
title = convertFileName(title);
return `${year}-${month}-${day}-${title}.md`;
}

Expand Down
Loading