Skip to content

Commit

Permalink
comment
Browse files Browse the repository at this point in the history
  • Loading branch information
shrimalmadhur committed Oct 10, 2023
1 parent 0b235f7 commit 13f4111
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions crypto/ecdsa/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ func WriteKey(path string, privateKey *ecdsa.PrivateKey, password string) error

func writeBytesToFile(path string, data []byte) error {
dir := filepath.Dir(path)

// create the directory if it doesn't exist. If exists, it does nothing
if err := os.MkdirAll(dir, 0755); err != nil {
fmt.Println("Error creating directories:", err)
return err
Expand Down

0 comments on commit 13f4111

Please sign in to comment.