Beispiel #1
0
        public FileSystemBlobProvider(IOptions <FileSystemBlobOptions> options)
        {
            _options = options.Value;

            // extra replace step to prevent windows path getting into linux environment
            _storagePath   = _options.RootPath.TrimEnd(Path.DirectorySeparatorChar).Replace('\\', Path.DirectorySeparatorChar);
            _basePublicUrl = _options.PublicUrl;
            _basePublicUrl = _basePublicUrl?.TrimEnd('/');
        }
        public FileSystemBlobProvider(IOptions <FileSystemBlobOptions> options)
        {
            _options = options.Value;

            _storagePath   = _options.RootPath.TrimEnd('\\');
            _basePublicUrl = _options.PublicUrl;
            if (_basePublicUrl != null)
            {
                _basePublicUrl = _basePublicUrl.TrimEnd('/');
            }
        }