mirror of
https://github.com/versity/versitygw.git
synced 2026-09-07 16:46:56 +00:00
chore: fix spellings and unused function args
No logic changes, just janitorial cleanup
This commit is contained in:
@@ -2,9 +2,10 @@ package command
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/versity/versitygw/tests/rest_scripts/logger"
|
||||
"os"
|
||||
"strings"
|
||||
|
||||
"github.com/versity/versitygw/tests/rest_scripts/logger"
|
||||
)
|
||||
|
||||
type OpenSSLCommand struct {
|
||||
@@ -64,14 +65,14 @@ func (o *OpenSSLCommand) Render() error {
|
||||
return fmt.Errorf("error writing to file: %w", err)
|
||||
}
|
||||
if o.Config.PayloadFile != "" || o.Config.Payload != "" {
|
||||
if err = o.writePayload(file); err != nil {
|
||||
if err = o.writePayload(); err != nil {
|
||||
return fmt.Errorf("error writing openssl payload: %w", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (o *OpenSSLCommand) writePayload(file *os.File) error {
|
||||
func (o *OpenSSLCommand) writePayload() error {
|
||||
if awsPayload, ok := o.payloadManager.(*PayloadStreamingAWS4HMACSHA256); ok {
|
||||
awsPayload.AddInitialSignatureAndSigningKey(o.signature, o.signingKey)
|
||||
}
|
||||
|
||||
@@ -6,11 +6,12 @@ import (
|
||||
"encoding/base64"
|
||||
"encoding/hex"
|
||||
"fmt"
|
||||
"github.com/versity/versitygw/tests/rest_scripts/logger"
|
||||
"os"
|
||||
"sort"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/versity/versitygw/tests/rest_scripts/logger"
|
||||
)
|
||||
|
||||
type S3Request struct {
|
||||
@@ -104,7 +105,7 @@ func (s *S3Request) calculateCanonicalRequestHash() error {
|
||||
|
||||
canonicalQuery, err := s.getCanonicalQuery()
|
||||
if err != nil {
|
||||
return fmt.Errorf("error generating canoncial query: %w", err)
|
||||
return fmt.Errorf("error generating canonical query: %w", err)
|
||||
}
|
||||
canonicalRequestLines = append(canonicalRequestLines, canonicalQuery)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user