1
0
mirror of https://github.com/mxpv/podsync.git synced 2024-05-11 05:55:04 +00:00

Fix issues with download links

This commit is contained in:
Maksym Pavlenko
2017-01-06 16:10:28 -08:00
parent 11b0e4b4d4
commit 9164833f4b
4 changed files with 7 additions and 9 deletions

View File

@@ -106,9 +106,9 @@ namespace Podsync.Services.Builder
};
}
private static IEnumerable<Item> CreateItems(IEnumerable<Video> videos)
private static Item[] CreateItems(IEnumerable<Video> videos)
{
return videos.Select(CreateItem);
return videos.Select(CreateItem).ToArray();
}
}
}

View File

@@ -55,7 +55,7 @@ namespace Podsync.Services.Builder
// Get video descriptions
var videos = await _youTube.GetVideos(new VideoQuery { Id = string.Join(",", ids) });
channel.Items = videos.Select(youtubeVideo => MakeItem(youtubeVideo, metadata));
channel.Items = videos.Select(youtubeVideo => MakeItem(youtubeVideo, metadata)).ToArray();
var rss = new Rss
{

View File

@@ -1,6 +1,4 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Xml;
using System.Xml.Schema;
using System.Xml.Serialization;
@@ -12,11 +10,10 @@ namespace Podsync.Services.Feed
public class Channel : IXmlSerializable
{
private const string PodsyncGeneratorName = "Podsync Generator";
private static readonly string DefaultItunesCategory = "TV & Film";
private const string DefaultItunesCategory = "TV & Film";
public Channel()
{
Items = Enumerable.Empty<Item>();
Category = DefaultItunesCategory;
LastBuildDate = DateTime.Now;
}
@@ -43,7 +40,7 @@ namespace Podsync.Services.Feed
public Uri Thumbnail { get; set; }
public IEnumerable<Item> Items { get; set; }
public Item[] Items { get; set; }
public bool Explicit { get; set; }

View File

@@ -21,7 +21,8 @@ namespace Podsync.Services.Links
{
[LinkType.Channel] = "https://vimeo.com/channels/{0}",
[LinkType.Group] = "https://vimeo.com/groups/{0}",
[LinkType.User] = "https://vimeo.com/{0}"
[LinkType.User] = "https://vimeo.com/user{0}",
[LinkType.Video] = "https://vimeo.com/{0}"
}
};