public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            ImageSource source = null;

            if (value != null)
            {
                byte[] byteArray = (byte[])value;
                var    fileType  = (string)parameter;
                if (fileType == "image")
                {
                    source = ImageSource.FromStream(() => new MemoryStream(byteArray));
                }
                else if (fileType == "svg")
                {
                    source = SvgImageSource.FromStream(() => new MemoryStream(byteArray));
                }
            }
            return(source);
        }