This commit is contained in:
parent
0e7d908e2f
commit
345aae3a9f
11
main.go
11
main.go
|
@ -492,11 +492,17 @@ func (h *graphHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||||
nodeMap := make(map[string]int)
|
nodeMap := make(map[string]int)
|
||||||
|
|
||||||
for key, references := range refs {
|
for key, references := range refs {
|
||||||
|
if strings.HasSuffix(key, "_2020") {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if _, e := nodeMap[key]; !e {
|
if _, e := nodeMap[key]; !e {
|
||||||
nodeMap[key] = nodeCount
|
nodeMap[key] = nodeCount
|
||||||
nodeCount += 1
|
nodeCount += 1
|
||||||
}
|
}
|
||||||
for _, item := range references {
|
for _, item := range references {
|
||||||
|
if strings.HasSuffix(item.Name, "_2020") {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if _, e := nodeMap[item.Name]; !e {
|
if _, e := nodeMap[item.Name]; !e {
|
||||||
nodeMap[item.Name] = nodeCount
|
nodeMap[item.Name] = nodeCount
|
||||||
nodeCount += 1
|
nodeCount += 1
|
||||||
|
@ -516,9 +522,12 @@ func (h *graphHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||||
if key == "DONE" {
|
if key == "DONE" {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
if strings.HasSuffix(key, "_2020") {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if toID, e := nodeMap[key]; e {
|
if toID, e := nodeMap[key]; e {
|
||||||
for _, item := range references {
|
for _, item := range references {
|
||||||
if item.Name == "Daily_Notes" && strings.HasSuffix(key, "_2020") {
|
if strings.HasSuffix(item.Name, "_2020") {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if fromID, e := nodeMap[item.Name]; e {
|
if fromID, e := nodeMap[item.Name]; e {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user