示例#1
0
 private bool EditAlbum(ImgurAlbum Album)
 {
     if (Album != null)
     {
     }
     return(false);
 }
示例#2
0
 public AlbumEntry(ImgurAlbum A)
 {
     DisplayName = A.title;
     if (string.IsNullOrEmpty(DisplayName))
     {
         DisplayName = "ID=" + A.id;
     }
     Id = A.id;
 }
示例#3
0
        /// <summary>
        /// Deletes an album
        /// </summary>
        /// <param name="I">Imgur album</param>
        /// <returns><see cref="true"/> on success</returns>
        /// <remarks>This will not delete images</remarks>
        public async Task <bool> DeleteAlbum(ImgurAlbum A)
        {
            HttpWebRequest R = Req(new Uri($"https://api.imgur.com/3/album/{A.deletehash}"));

            R.Method = "DELETE";
            using (HttpWebResponse Res = await GetResponse(R))
            {
                string data = await ReadAll(Res.GetResponseStream());

                return(!ProcessErrorResponse(data) && !IsErrorCode(Res.StatusCode));
            }
        }