Skip to content

Commit

Permalink
refactor: 🔥 Remove unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
SkepticMystic committed Jan 16, 2022
1 parent 175bef6 commit 5e7d46a
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 17 deletions.
6 changes: 4 additions & 2 deletions src/Codeblocks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ export function getCodeblockCB(plugin: BCPlugin) {
const allPaths = dfsAllPaths(subClosed, basename);
const index = createIndex(allPaths, false);
info({ allPaths, index });
console.log({ allPaths, index });

const lines = index
.split("\n")
.map((line) => {
Expand Down Expand Up @@ -342,7 +342,9 @@ class BCStore extends Component implements ICoreDataStore {
console.log("returning empty cache", nodeId);
return Promise.resolve(nodeDangling(nodeId.id));
}
return Promise.resolve(nodeFromFile(file, this.plugin, view.settings, nodeId.toId()));
return Promise.resolve(
nodeFromFile(file, this.plugin, view.settings, nodeId.toId())
);
}
}

Expand Down
10 changes: 2 additions & 8 deletions src/Commands/CreateIndex.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
import { cloneDeep } from "lodash";
import { info } from "loglevel";
import { copy } from "obsidian-community-lib/dist/utils";
import { makeWiki } from "../sharedFunctions";
import {
dfsAllPaths,
getReflexiveClosure,
getSinks,
getSubCloseSub,
getSubInDirs,
} from "../graphUtils";
import { dfsAllPaths, getSinks, getSubInDirs } from "../graphUtils";
import type BCPlugin from "../main";
import { makeWiki } from "../sharedFunctions";

/**
* Returns a copy of `index`, doesn't mutate.
Expand Down
10 changes: 5 additions & 5 deletions src/Views/MatrixView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
MATRIX_VIEW,
TRAIL_ICON,
} from "../constants";
import { getOppDir, getReflexiveClosure, getSubInDirs } from "../graphUtils";
import { getOppDir, getSubInDirs } from "../graphUtils";
import type {
Directions,
internalLinkObj,
Expand Down Expand Up @@ -133,14 +133,14 @@ export default class MatrixView extends ItemView {
} = blankRealNImplied();

const resultsFilter = (
real: SquareItem,
item: SquareItem,
dir: Directions,
oppDir: Directions,
arrow: string
) =>
hier[dir].includes(real.field) ||
(real.field.includes(`<${arrow}>`) &&
hier[oppDir].includes(real.field.split(" <")[0]));
hier[dir].includes(item.field) ||
(item.field.includes(`<${arrow}>`) &&
hier[oppDir].includes(item.field.split(" <")[0]));

for (const dir in realsnImplieds) {
const oppDir = getOppDir(dir as Directions);
Expand Down
1 change: 0 additions & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import {
wait,
waitForResolvedLinks,
} from "obsidian-community-lib/dist/utils";
import { getReflexiveClosure } from "./graphUtils";
import { Debugger } from "src/Debugger";
import { HierarchyNoteSelectorModal } from "./AlternativeHierarchies/HierarchyNotes/HierNoteModal";
import { BCSettingTab } from "./BreadcrumbsSettingTab";
Expand Down
1 change: 0 additions & 1 deletion src/refreshIndex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,6 @@ function addAuntsUncles(g: MultiGraph) {
g.forEachOutEdge(parentNode, (k, a, s, uncle) => {
if (a.dir !== "same") return;

console.log("aunt", currN, uncle);
addEdgeIfNot(g, currN, uncle, {
dir: "up",
// Use the starting nodes parent field
Expand Down

0 comments on commit 5e7d46a

Please sign in to comment.