Skip to content

Commit

Permalink
replace former import with new import_file
Browse files Browse the repository at this point in the history
  • Loading branch information
Brian Joseph Petro committed Aug 25, 2024
1 parent 74c36eb commit ab2f02a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ export default class SmartConnectionsPlugin extends Plugin {
// delte note entity from collection
this.env.smart_sources.delete_item(curr_file.path);
// import note
await this.env.smart_sources.import([curr_file]);
await this.env.smart_sources.import_file(curr_file);
setTimeout(() => {
// refresh view
this.view.render_nearest();
Expand Down
2 changes: 1 addition & 1 deletion src/sc_smart_view.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ export class ScSmartView extends SmartObsidianView {
if(this.env.fs.is_excluded(context.path)){
return this.plugin.notices.show('excluded file', "File is excluded: " + context.path, {timeout: 3000});
}else{
await this.env.smart_sources.import([context]);
await this.env.smart_sources.import_file(context);
}
}
// wait for context.vec (prevent infinite loop)
Expand Down

0 comments on commit ab2f02a

Please sign in to comment.