mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-07-01 11:23:36 +02:00
update connection manager
This commit is contained in:
parent
b28df6a731
commit
3ec7ceac02
|
@ -165,7 +165,7 @@ namespace MediaBrowser.Providers.Omdb
|
|||
|
||||
var imdbId = result.Item.GetProviderId(MetadataProviders.Imdb);
|
||||
|
||||
if (!string.IsNullOrEmpty(info.GetProviderId(MetadataProviders.Imdb)))
|
||||
if (!string.IsNullOrEmpty(imdbId))
|
||||
{
|
||||
result.Item.SetProviderId(MetadataProviders.Imdb, imdbId);
|
||||
result.HasMetadata = true;
|
||||
|
@ -195,7 +195,7 @@ namespace MediaBrowser.Providers.Omdb
|
|||
var searchResult = await GetMovieImdbId(info, cancellationToken).ConfigureAwait(false);
|
||||
result.Item.Name = searchResult.Item3;
|
||||
|
||||
if (string.IsNullOrEmpty(imdbId))
|
||||
if (string.IsNullOrWhiteSpace(imdbId))
|
||||
{
|
||||
imdbId = searchResult.Item1;
|
||||
|
||||
|
@ -205,7 +205,7 @@ namespace MediaBrowser.Providers.Omdb
|
|||
}
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(imdbId))
|
||||
if (!string.IsNullOrWhiteSpace(imdbId))
|
||||
{
|
||||
result.Item.SetProviderId(MetadataProviders.Imdb, imdbId);
|
||||
result.HasMetadata = true;
|
||||
|
|
|
@ -29,6 +29,11 @@ namespace MediaBrowser.Providers.Omdb
|
|||
|
||||
public async Task Fetch(BaseItem item, string imdbId, CancellationToken cancellationToken)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(imdbId))
|
||||
{
|
||||
throw new ArgumentNullException("imdbId");
|
||||
}
|
||||
|
||||
var imdbParam = imdbId.StartsWith("tt", StringComparison.OrdinalIgnoreCase) ? imdbId : "tt" + imdbId;
|
||||
|
||||
var url = string.Format("http://www.omdbapi.com/?i={0}&tomatoes=true", imdbParam);
|
||||
|
|
|
@ -59,14 +59,7 @@ namespace MediaBrowser.WebDashboard.Api
|
|||
{
|
||||
// Don't apply any caching for html pages
|
||||
// jQuery ajax doesn't seem to handle if-modified-since correctly
|
||||
if (IsFormat(path, "html"))
|
||||
{
|
||||
if (path.IndexOf("cordovaindex.html", StringComparison.OrdinalIgnoreCase) == -1)
|
||||
{
|
||||
resourceStream = await ModifyHtml(resourceStream, mode, localizationCulture, enableMinification).ConfigureAwait(false);
|
||||
}
|
||||
}
|
||||
else if (IsFormat(path, "js"))
|
||||
if (IsFormat(path, "js"))
|
||||
{
|
||||
if (path.IndexOf("thirdparty", StringComparison.OrdinalIgnoreCase) == -1)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue