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

Title: Error when Exporting Flashcards from Obsidian to Anki: TypeError in CardsService.updateFrontmatter #632

Open
TammoR opened this issue Jan 3, 2025 · 0 comments

Comments

@TammoR
Copy link

TammoR commented Jan 3, 2025

I am experiencing an error when using the Obsidian plugin to export flashcards to Anki. Below are the details of the error message and the relevant code snippets.

plugin:flashcards-obsidian:6922 TypeError: Cannot read properties of undefined (reading 'start')
    at CardsService.updateFrontmatter (plugin:flashcards-obsidian:6933:75)
    at CardsService.eval (plugin:flashcards-obsidian:6916:30)
    at step (plugin:flashcards-obsidian:68:23)
    at Object.eval [as next] (plugin:flashcards-obsidian:49:53)
    at fulfilled (plugin:flashcards-obsidian:39:58)
Code Snippet (Lines 6932, 6933):

Here is plugin:flashcards-obsidian:6932:

if (frontmatter) {
    var oldFrontmatter = this.file.substring(frontmatter.position.start.offset, frontmatter.position.end.offset);

It looks like frontmatter has no position attribute.

This is on Anki 24.11 and Obsidian 1.7.7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant