Skip to content

Commit

Permalink
Merge pull request #31 from mutjan/master
Browse files Browse the repository at this point in the history
Simple fix for empty property and empty inline dataview problem
  • Loading branch information
natefrisch01 committed May 5, 2024
2 parents c6d9a4d + d149196 commit 7fecf1f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "graph-link-types",
"name": "Graph Link Types",
"version": "0.3.1",
"version": "0.3.2",
"minAppVersion": "1.5.0",
"description": "Link types for graph view.",
"author": "natefrisch01",
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "graph-link-types",
"version": "0.1.2",
"version": "0.3.2",
"description": "Link types for Obsidian graph view.",
"main": "main.js",
"scripts": {
Expand Down
6 changes: 5 additions & 1 deletion src/linkManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,10 @@ export class LinkManager {
if (!sourcePage) return null;

for (const [key, value] of Object.entries(sourcePage)) {
// Skip empty values
if (value === null || value === undefined || value === '') {
continue;
}
const valueType = this.determineDataviewLinkType(value);

switch (valueType) {
Expand Down Expand Up @@ -497,4 +501,4 @@ export class LinkManager {
return { px, py };
}

}
}

0 comments on commit 7fecf1f

Please sign in to comment.