fix file playback
This commit is contained in:
parent
e5d3f6935d
commit
85dbbd8bfc
@ -20,7 +20,7 @@ namespace TomatenMusic.Music.Entitites
|
|||||||
public IEnumerable<string> YoutubeTags { get; set; }
|
public IEnumerable<string> YoutubeTags { get; set; }
|
||||||
public ulong YoutubeViews { get; set; }
|
public ulong YoutubeViews { get; set; }
|
||||||
public ulong YoutubeLikes { get; set; }
|
public ulong YoutubeLikes { get; set; }
|
||||||
public Uri YoutubeThumbnail { get; set; }
|
public Uri? YoutubeThumbnail { get; set; } = null;
|
||||||
public DateTime YoutubeUploadDate { get; set; }
|
public DateTime YoutubeUploadDate { get; set; }
|
||||||
//
|
//
|
||||||
// Summary:
|
// Summary:
|
||||||
|
@ -32,10 +32,12 @@ namespace TomatenMusic.Util
|
|||||||
DiscordEmbedBuilder builder = new DiscordEmbedBuilder()
|
DiscordEmbedBuilder builder = new DiscordEmbedBuilder()
|
||||||
.WithTitle(track.Title)
|
.WithTitle(track.Title)
|
||||||
.WithUrl(track.Source)
|
.WithUrl(track.Source)
|
||||||
.WithImageUrl(context.YoutubeThumbnail)
|
|
||||||
.WithDescription(context.YoutubeDescription)
|
.WithDescription(context.YoutubeDescription)
|
||||||
.AddField("Length", Common.GetTimestamp(track.Duration), true);
|
.AddField("Length", Common.GetTimestamp(track.Duration), true);
|
||||||
|
|
||||||
|
if (context.YoutubeThumbnail != null)
|
||||||
|
builder.WithImageUrl(context.YoutubeThumbnail);
|
||||||
|
|
||||||
if (context.IsFile)
|
if (context.IsFile)
|
||||||
{
|
{
|
||||||
builder.WithAuthor(track.Author);
|
builder.WithAuthor(track.Author);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user