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

[Bug?] Using prepend in note with frontmatter causes an error, so it does nothing except focus Obsidian #148

Closed
kauffy opened this issue Oct 21, 2023 · 0 comments

Comments

@kauffy
Copy link

kauffy commented Oct 21, 2023

I am wanting to create a global hotkey that opens Obsidian and places me into a specific note, wherein it inserts a datestamp and I can begin typing.

Since I want the newest entries to be at the top, I am using prepend.

Unfortunately, when I fire this URI URL (obsidian://advanced-uri?vault=obsidian&filepath=_Meta-Utils%2FScratch&data=test&mode=prepend) off, it opens Obsidian, but then does nothing else. I looked in the console to see that it's choking on the frontmatter (I made a sample file with minimalized frontmatter, after it didn't work with more complex frontmatter)-- it does work if the file has no frontmatter.

Received URL action {vault: 'obsidian', filepath: '_Meta-Utils/Scratch', data: 'shit', mode: 'prepend', action: 'advanced-uri'} plugin:obsidian-advanced-uri:4707 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'end') at AdvancedURI.prepend (plugin:obsidian-advanced-uri:4707:51) at async Handlers.handleWrite (plugin:obsidian-advanced-uri:3833:21)

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