Ejemplo n.º 1
0
        public virtual async Task <FileResult> GetFriendProfilePicture(long userId, int?tenantId)
        {
            var output = await _profileAppService.GetFriendProfilePicture(new GetFriendProfilePictureInput()
            {
                TenantId = tenantId,
                UserId   = userId
            });

            if (output.ProfilePicture.IsNullOrEmpty())
            {
                return(GetDefaultProfilePictureInternal());
            }

            return(File(Convert.FromBase64String(output.ProfilePicture), MimeTypeNames.ImageJpeg));
        }