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

button action "update Metadata" cannot find function getMetadata #371

Closed
4 of 7 tasks
Yurhmz opened this issue Jul 2, 2024 · 1 comment
Closed
4 of 7 tasks

button action "update Metadata" cannot find function getMetadata #371

Yurhmz opened this issue Jul 2, 2024 · 1 comment
Labels
bug Undesired behavior caused by this plugin

Comments

@Yurhmz
Copy link

Yurhmz commented Jul 2, 2024

Please fill out these Check-boxes

  • I checked that the plugin is up to date
  • The issue persist with all other plugins and themes disabled

This Issue Occurs on

  • Windows
  • Linux
  • macOS
  • Android
  • iOS

Plugin Version

1.1.2

Describe the Issue

using the update Metadata button Action example in the Example vault, I get an error "getMetadata is not defined" in the console.

here is the full report form console :

plugin:obsidian-meta-bind-plugin:51 meta-bind | ButtonMDRC >> error while running action ReferenceError: getMetadata is not defined
    at eval (eval at runUpdateMetadataAction (plugin:obsidian-meta-bind-plugin:1:1), <anonymous>:3:1)
    at Vh.updateMetadata (plugin:obsidian-meta-bind-plugin:111:18106)
    at _p.runUpdateMetadataAction (plugin:obsidian-meta-bind-plugin:51:8971)
    at _p.runAction (plugin:obsidian-meta-bind-plugin:51:7071)
    at _p.runButtonAction (plugin:obsidian-meta-bind-plugin:51:5269)
    at onClick (plugin:obsidian-meta-bind-plugin:57:14656)
    at f (plugin:obsidian-meta-bind-plugin:57:13305)
    at HTMLButtonElement.p (plugin:obsidian-meta-bind-plugin:57:13406)
runButtonAction @ plugin:obsidian-meta-bind-plugin:51
await in runButtonAction (async)
onClick @ plugin:obsidian-meta-bind-plugin:57
f @ plugin:obsidian-meta-bind-plugin:57
p @ plugin:obsidian-meta-bind-plugin:57

Steps to Reproduce

  1. copy the code from the Example vault from line 208 to 263
  2. paste in an obsidian note
  3. click the buttons newly created
  4. note that the buttons "+1" "reset" and "-1" work as expected
  5. note that the button "add count to count2" returns an error "getMetadata is not defined" in the console

Expected Behavior

clicking on "add count to count2" should use the "getMetadata" function and allow for calculation with multiple variables in the file.

@Yurhmz Yurhmz added the bug Undesired behavior caused by this plugin label Jul 2, 2024
@mProjectsCode
Copy link
Owner

The function is not officially released yet, it's only available in the current canary release.

Read more about the example vault and WIP features in the docs.

@mProjectsCode mProjectsCode closed this as not planned Won't fix, can't repro, duplicate, stale Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Undesired behavior caused by this plugin
Projects
None yet
Development

No branches or pull requests

2 participants