File tree Expand file tree Collapse file tree 4 files changed +8
-4
lines changed Expand file tree Collapse file tree 4 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"id" : " metaedit" ,
3
3
"name" : " MetaEdit" ,
4
- "version" : " 1.6.9 " ,
4
+ "version" : " 1.6.10 " ,
5
5
"minAppVersion" : " 0.12.0" ,
6
6
"description" : " MetaEdit helps you manage your metadata." ,
7
7
"author" : " Christian B. B. Houmann" ,
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " metaedit" ,
3
- "version" : " 1.6.9 " ,
3
+ "version" : " 1.6.10 " ,
4
4
"description" : " MetaEdit helps you manage your metadata." ,
5
5
"main" : " main.js" ,
6
6
"scripts" : {
Original file line number Diff line number Diff line change @@ -180,7 +180,11 @@ export default class MetaEdit extends Plugin {
180
180
181
181
if ( links ) {
182
182
for ( const link of links ) {
183
- const linkFile : TAbstractFile = this . app . vault . getAbstractFileByPath ( `${ link . link } .md` ) ;
183
+ // Because of how links are formatted, I have to do it this way.
184
+ // If there are duplicates (two files with the same name) for a link, the path will be in the link.
185
+ // If not, the link won't specify the folder. Therefore, we check all files.
186
+ const markdownFiles : TFile [ ] = this . app . vault . getMarkdownFiles ( ) ;
187
+ const linkFile : TFile = markdownFiles . find ( f => f . path . includes ( `${ link . link } .md` ) ) ;
184
188
185
189
if ( linkFile instanceof TFile ) {
186
190
const heading = this . getTaskHeading ( link . link , fileContent ) ;
Original file line number Diff line number Diff line change 1
1
{
2
- "1.6.9 " : " 0.12.0"
2
+ "1.6.10 " : " 0.12.0"
3
3
}
You can’t perform that action at this time.
0 commit comments