mirror of
https://github.com/drakkan/sftpgo.git
synced 2025-12-07 23:00:55 +03:00
add an util method to convert []byte to string
Signed-off-by: Nicola Murino <nicola.murino@gmail.com>
This commit is contained in:
@@ -196,7 +196,7 @@ Please take a look at the usage below to customize the serving parameters`,
|
||||
fmt.Printf("Unable to read password file %q: %v", portablePasswordFile, err)
|
||||
os.Exit(1)
|
||||
}
|
||||
pwd = strings.TrimSpace(string(content))
|
||||
pwd = strings.TrimSpace(util.BytesToString(content))
|
||||
}
|
||||
service.SetGraceTime(graceTime)
|
||||
service := service.Service{
|
||||
@@ -523,7 +523,7 @@ func getFileContents(name string) (string, error) {
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
return string(contents), nil
|
||||
return util.BytesToString(contents), nil
|
||||
}
|
||||
|
||||
func convertFsProvider() string {
|
||||
|
||||
Reference in New Issue
Block a user