Commit f2d74143 authored by Eric's avatar Eric

Merge branch 'dev' of https://github.com/jumpserver/koko into dev_bugfix

parents 7c6c71e5 d9fcb341
...@@ -28,7 +28,11 @@ func NewUserVolume(user *model.User, addr, hostId string) *UserVolume { ...@@ -28,7 +28,11 @@ func NewUserVolume(user *model.User, addr, hostId string) *UserVolume {
default: default:
assets := service.GetUserAssetByID(user.ID, hostId) assets := service.GetUserAssetByID(user.ID, hostId)
if len(assets) == 1 { if len(assets) == 1 {
homename = assets[0].Hostname folderName := assets[0].Hostname
if strings.Contains(folderName, "/") {
folderName = strings.ReplaceAll(folderName, "/", "_")
}
homename = folderName
basePath = filepath.Join("/", homename) basePath = filepath.Join("/", homename)
} }
userSftp = srvconn.NewUserSftpConnWithAssets(user, addr, assets...) userSftp = srvconn.NewUserSftpConnWithAssets(user, addr, assets...)
......
...@@ -16,7 +16,7 @@ import ( ...@@ -16,7 +16,7 @@ import (
"github.com/jumpserver/koko/pkg/sshd" "github.com/jumpserver/koko/pkg/sshd"
) )
const Version = "1.5.5" const Version = "1.5.6"
type Coco struct { type Coco struct {
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment