SuperPutty.Data.SessionData.GetSessionParentId C# (CSharp) Method

GetSessionParentId() public static method

Get the parent ID of the specified session
public static GetSessionParentId ( string sessionId ) : string
sessionId string the ID of the session
return string
        public static string GetSessionParentId(string sessionId)
        {
            string parentPath = null;
            if (sessionId != null)
            {
                int idx = sessionId.LastIndexOf('/');
                if (idx != -1)
                {
                    parentPath = sessionId.Substring(0, idx);
                }
            }
            return parentPath;
        }