Пример #1
0
        /// <summary>
        /// Sets the image url in the PostModel instance specified.
        /// </summary>
        /// <param name="picFile"></param>
        /// <param name="path"></param>
        /// <param name="post"></param>
        /// <returns></returns>
        private async Task <string> GetImageUrl(HttpPostedFile picFile, string path)
        {
            string urlToReturn = "";

            if (picFile != null)
            {
                urlToReturn = await _storageManager.AddPicToStorage(picFile, path).ConfigureAwait(false);
            }

            return(urlToReturn);
        }