Src/Pscx/Providers/FeedStoreProvider.cs
/// <summary>
/// Adapts the path, making sure the correct path separator
/// character is used.
/// </summary>
/// <param name="path"></param>
/// <returns></returns>
Adapts the path, making sure the correct path separator
character is used.
Adapts the path making sure the correct path separator character is used .
private string NormalizePath(string path)
        {
            if (String.IsNullOrEmpty(path)) return path;
            string result = path.Replace("/", _pathSeparator);
            if (result.StartsWith(_pathSeparator))
            {
                result = result.Substring(_pathSeparator.Length);
            }
            if (result.EndsWith(_pathSeparator))
            {
                result = result.Substring(0, result.Length - _pathSeparator.Length);
            }
            return result;
        }
private string NormalizePath ( string path ) { if ( String . IsNullOrEmpty ( path ) ) return path ; string result = path . Replace ( " " , _pathSeparator ) ; if ( result . StartsWith ( _pathSeparator ) ) { result = result . Substring ( _pathSeparator . Length ) ; } if ( result . EndsWith ( _pathSeparator ) ) { result = result . Substring ( 0 , result . Length - _pathSeparator . Length ) ; } return result ; }
Adapts the path, making sure the correct path separator
character is used.
Adapts the path making sure the correct path separator character is used .
None
path
string
None