Skip to content

Commit

Permalink
(*Node).Info is now a full copy of os.FileInfo instead of a pointer
Browse files Browse the repository at this point in the history
Also moved tree.go to match package name

This seems to break testing? Though not sure why..

Renaming was a 2 second change to fix 🤷
  • Loading branch information
Zachary Scott committed Jun 14, 2018
1 parent 3cd4f39 commit e43ef6b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions filetree/tree.go → filetree/filetree.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
// Node represents a leaf in the filetree
type Node struct {
FullPath string
Info *os.FileInfo
Info os.FileInfo
Children []*Node
Parent *Node
}
Expand Down Expand Up @@ -44,7 +44,7 @@ func NewTree(root string) (*Node, error) {

parents[path] = &Node{
FullPath: path,
Info: &info,
Info: info,
Children: make([]*Node, 0),
}
return nil
Expand Down

0 comments on commit e43ef6b

Please sign in to comment.