Fix scenetime

This commit is contained in:
KZ 2015-08-10 21:46:58 +01:00
parent ccde119454
commit 0a2d0b40fb
2 changed files with 2 additions and 6 deletions

View File

@ -45,7 +45,7 @@ Download in the [Releases page](https://github.com/zone117x/Jackett/releases)
* [TorrentLeech](http://www.torrentleech.org/)
* [TorrentShack](http://torrentshack.me/)
* [Torrentz](https://torrentz.eu/)
* [TV Chaos UK](https://tvchaosuk.com/)
#### Installation on Linux/OSX
1. Install [Mono 4](http://www.mono-project.com/download/) or better

View File

@ -95,11 +95,7 @@ namespace Jackett.Indexers
var torrentId = qLink.Attr("href").Split('=')[1];
release.Link = new Uri(string.Format(DownloadUrl, torrentId));
var dateStr = descCol.ChildNodes.Last().NodeValue.Trim();
var euDate = DateTime.ParseExact(dateStr, "yyyy-MM-dd HH:mm:ss", CultureInfo.InvariantCulture);
var timezoneString = Environment.OSVersion.Platform == PlatformID.Unix ? "Europe/Berlin" : "Central European Standard Time";
var localDate = TimeZoneInfo.ConvertTimeToUtc(euDate, TimeZoneInfo.FindSystemTimeZoneById(timezoneString)).ToLocalTime();
release.PublishDate = localDate;
release.PublishDate = DateTimeUtil.FromTimeAgo(descCol.ChildNodes.Last().InnerText);
var sizeStr = row.ChildElements.ElementAt(5).Cq().Text();
release.Size = ReleaseInfo.GetBytes(sizeStr);