mirror of
https://github.com/wavetermdev/backup.git
synced 2026-08-05 13:57:07 -07:00
getsessionsdir
This commit is contained in:
@@ -157,6 +157,12 @@ func CleanUpCmdFiles(sessionId string, cmdId string) error {
|
||||
return err
|
||||
}
|
||||
|
||||
func GetSessionsDir() string {
|
||||
mhome := GetMShellHomeDir()
|
||||
sdir := path.Join(mhome, SessionsDirBaseName)
|
||||
return sdir
|
||||
}
|
||||
|
||||
func EnsureSessionDir(sessionId string) (string, error) {
|
||||
if sessionId == "" {
|
||||
return "", fmt.Errorf("Bad sessionid, cannot be empty")
|
||||
|
||||
Reference in New Issue
Block a user