Skip to content

Commit

Permalink
fix format placeholders
Browse files Browse the repository at this point in the history
  • Loading branch information
Hou Junjie committed Jan 5, 2021
1 parent c403512 commit 0312119
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 5 deletions.
5 changes: 5 additions & 0 deletions src/csi/driver/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -319,3 +319,8 @@ func (d *Driver) DeleteSnapshot(ctx context.Context, req *csi.DeleteSnapshotRequ
func (d *Driver) ListSnapshots(ctx context.Context, req *csi.ListSnapshotsRequest) (*csi.ListSnapshotsResponse, error) {
return nil, status.Error(codes.Unimplemented, "")
}

func (d *Driver) ControllerGetVolume(ctx context.Context, req *csi.ControllerGetVolumeRequest) (*csi.ControllerGetVolumeResponse, error) {
// todo
return nil, nil
}
2 changes: 1 addition & 1 deletion src/storage/fusionstorage/smartx/smartx.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func (p *QoS) AddQoS(volName string, params map[string]int) (string, error) {

err := p.RemoveQoS(volName)
if err != nil {
log.Errorf("Revert Create qos %s error: %v", params, err)
log.Errorf("Revert Create qos %v error: %v", params, err)
return "", err
}

Expand Down
2 changes: 1 addition & 1 deletion src/storage/fusionstorage/volume/san.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ func (p *SAN) preExpandCheckCapacity(params, taskResult map[string]interface{})
expandSize := params["expandSize"].(int64)
pool, err := p.cli.GetPoolById(localParentId)
if err != nil || pool == nil {
log.Errorf("Get storage pool %s info error: %v", localParentId, err)
log.Errorf("Get storage pool %v info error: %v", localParentId, err)
return nil, err
}
totalCapacity := int64(pool["totalCapacity"].(float64))
Expand Down
4 changes: 2 additions & 2 deletions src/tools/passwdEncrypt/passwdEncrypt.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ func main() {
fmt.Print("Enter password: ")
input, err := terminal.ReadPassword(0)
if err != nil {
fmt.Println("Input password error: %v", err)
fmt.Printf("Input password error: %v", err)
os.Exit(1)
}

Expand All @@ -27,7 +27,7 @@ func main() {

encrypted, err := pwd.Encrypt(plainText)
if err != nil {
fmt.Println("Encrypt password error: %v", err)
fmt.Printf("Encrypt password error: %v", err)
os.Exit(1)
}

Expand Down
2 changes: 1 addition & 1 deletion src/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ func CopyMap(srcMap interface{}) map[string]interface{} {
func StrToBool(str string) bool {
b, err := strconv.ParseBool(str)
if err != nil {
log.Warningf("Parse bool string %s error, return false")
log.Warningf("Parse bool string %s error, return false", err)
return false
}

Expand Down

0 comments on commit 0312119

Please sign in to comment.