Skip to content

Commit

Permalink
Add comment for posterity
Browse files Browse the repository at this point in the history
  • Loading branch information
cemremengu committed Feb 12, 2019
1 parent 6d0a366 commit 58c42f2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ type FileSystem struct {
func (fs FileSystem) Open(path string) (http.File, error) {
f, err := fs.fs.Open(path)
if err != nil {
// if not found, we assume a virtual path and delagate routing to application
f, _ = fs.fs.Open(fmt.Sprintf("/%s", fs.root))
}

Expand Down

0 comments on commit 58c42f2

Please sign in to comment.