Skip to content

Commit

Permalink
Fix linter issue
Browse files Browse the repository at this point in the history
Signed-off-by: Md. Ishtiaq Islam <[email protected]>
  • Loading branch information
ishtiaqhimel committed Aug 20, 2024
1 parent da85d04 commit 5547c0a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions pkg/cmds/create_volumesnapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -231,8 +231,7 @@ func (opt *VSoption) createVolumeSnapshot(bsMeta metav1.ObjectMeta, inv invoker.
}
err := prober.RunProbe(opt.config, targetInfo.Hooks.PostBackup.Handler, podName, opt.namespace)
if err != nil {
return nil, fmt.Errorf(err.Error() + "Warning: The actual backup process may be succeeded." +
"Hence, the backup snapshots might be present in the backend even if the overall BackupSession phase is 'Failed'")
return nil, fmt.Errorf("%w Warning: The actual backup process may be succeeded. Hence, the backup snapshots might be present in the backend even if the overall BackupSession phase is 'Failed'", err)
}
backupOutput.BackupTargetStatus.Conditions = append(backupOutput.BackupTargetStatus.Conditions, kmapi.Condition{
Type: api_v1beta1.PostBackupHookExecutionSucceeded,
Expand Down
3 changes: 1 addition & 2 deletions pkg/cmds/restore_volumesnapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -254,8 +254,7 @@ func (opt *VSoption) restoreVolumeSnapshot(targetInfo invoker.RestoreTargetInfo)
}
err := prober.RunProbe(opt.config, targetInfo.Hooks.PostRestore.Handler, podName, opt.namespace)
if err != nil {
return nil, fmt.Errorf(err.Error() + "Warning: The actual restore process may be succeeded." +
"Hence, the restored data might be present in the target even if the overall RestoreSession phase is 'Failed'")
return nil, fmt.Errorf("%w Warning: The actual restore process may be succeeded. Hence, the restored data might be present in the target even if the overall RestoreSession phase is 'Failed'", err)
}
klog.Infoln("postRestore hooks has been executed successfully")
}
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/minio_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ func (f *Framework) SecretForMinioServer(ips []net.IP) core.Secret {

return core.Secret{
ObjectMeta: metav1.ObjectMeta{
Name: fmt.Sprintf(MinioServerSecret + f.namespace),
Name: MinioServerSecret + f.namespace,
Namespace: f.namespace,
},
Data: map[string][]byte{
Expand Down

0 comments on commit 5547c0a

Please sign in to comment.