Skip to content

Commit

Permalink
Update keystore.go
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsan6sha committed Nov 1, 2023
1 parent 0404eb1 commit abadfa6
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions blockchain/keystore.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,7 @@ func NewSimpleKeyStorer(dbPath string) *SimpleKeyStorer {
err := os.MkdirAll(dbPath, 0755)
if err != nil {
// Fallback to a local directory
dbPath = "./internal/.secrets"
if _, err := os.Stat(dbPath); os.IsNotExist(err) {
err = os.MkdirAll(dbPath, 0755)
if err != nil {
panic("Failed to create fallback directory: " + err.Error())
}
}
dbPath = "."
}
}

Expand Down

0 comments on commit abadfa6

Please sign in to comment.