Skip to content
This repository has been archived by the owner on Apr 9, 2024. It is now read-only.

Commit

Permalink
Add a terminating newline at the end of generated endorsement statement
Browse files Browse the repository at this point in the history
  • Loading branch information
rbehjati committed Aug 3, 2023
1 parent d9148f0 commit 9f5fa3c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/endorser/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,9 @@ func main() {
log.Fatalf("Failed marshalling the endorsement: %v", err)
}

// Add a newline at the end of the file.
newline := []byte("\n")[0]
bytes = append(bytes, newline)
if err := os.WriteFile(opt.endorsementPath, bytes, 0600); err != nil {
log.Fatalf("Failed writing the endorsement statement to file: %v", err)
}
Expand Down

0 comments on commit 9f5fa3c

Please sign in to comment.