This commit is contained in:
Alexey Golub
2018-06-27 00:30:02 +03:00
parent 69088b83eb
commit 23f9331e4e
4 changed files with 32 additions and 36 deletions

View File

@@ -6,19 +6,24 @@
{
public string Id { get; }
public bool IsImage { get; }
public string Url { get; }
public int? Width { get; }
public int? Height { get; }
public bool IsImage => Width != null;
public string FileName { get; }
public long FileSize { get; }
public Attachment(string id, bool isImage, string url, string fileName, long fileSize)
public Attachment(string id, int? width, int? height, string url, string fileName, long fileSize)
{
Id = id;
IsImage = isImage;
Url = url;
Width = width;
Height = height;
FileName = fileName;
FileSize = fileSize;
}

View File

@@ -6,11 +6,11 @@ namespace DiscordChatExporter.Core.Models
{
public string Url { get; }
public int? Height { get; }
public int? Width { get; }
public EmbedImage(string url, int? height, int? width)
public int? Height { get; }
public EmbedImage(string url, int? width, int? height)
{
Url = url;
Height = height;