/// <summary>
        /// Creates a new ImageBlock saved to @parent's assets folder
        /// </summary>
        /// <param name="parent"></param>
        /// <param name="url"></param>
        /// <param name="title"></param>
        /// <returns></returns>
        public static ImageBlock CreateImageBlock(ContentReference parent, string url, string title)
        {
            ImageFile imageFile = ImageDownloaderHelper.DownloadImage(parent, url, title);
            var       t         = title ?? "untitled";

            if (imageFile != null)
            {
                ImageBlock imgBlock =
                    parent.CreateGenericBlockForPage <ImageBlock>($"ImageBlock - {t}");
                imgBlock.ImageReference = imageFile.ContentLink;
                imgBlock.Title          = t;
                return(imgBlock);
            }

            return(null);
        }
        /// <summary>
        /// Downloads an image from the url and saves to parents assets folder
        /// </summary>
        /// <param name="parent"></param>
        /// <param name="url"></param>
        /// <param name="title"></param>
        /// <returns></returns>
        public static ImageFile DownloadImage(ContentReference parent, string url, string title)
        {
            var imageFile = Repo.GetDefault <ImageFile>(ContentAssetHelper.GetOrCreateAssetFolder(parent).ContentLink);

            imageFile.Name = $"image-{title}";
            var blob = ImageDownloaderHelper.DownloadImageBlob(url);

            if (blob != null)
            {
                imageFile.BinaryData = blob;
                Repo.Save(imageFile, SaveAction.Publish);
                return(imageFile);
            }

            return(null);
        }