Fix regression where it would do integer divisions, giving wrong result

This commit is contained in:
hawken 2019-01-07 21:10:11 +00:00
parent c986340c02
commit 880825514a
5 changed files with 6 additions and 6 deletions

View File

@ -64,7 +64,7 @@ namespace MediaBrowser.Controller.Entities.Movies
} }
public override double GetDefaultPrimaryImageAspectRatio() public override double GetDefaultPrimaryImageAspectRatio()
=> 2 / 3; => 2.0 / 3;
public override UnratedItem GetBlockUnratedType() public override UnratedItem GetBlockUnratedType()
{ {

View File

@ -51,7 +51,7 @@ namespace MediaBrowser.Controller.Entities.Movies
return 0; return 0;
} }
return 2 / 3; return 2.0 / 3;
} }
protected override async Task<bool> RefreshedOwnedItems(MetadataRefreshOptions options, List<FileSystemMetadata> fileSystemChildren, CancellationToken cancellationToken) protected override async Task<bool> RefreshedOwnedItems(MetadataRefreshOptions options, List<FileSystemMetadata> fileSystemChildren, CancellationToken cancellationToken)

View File

@ -111,7 +111,7 @@ namespace MediaBrowser.Controller.Entities.TV
return 0; return 0;
} }
return 16 / 9; return 16.0 / 9;
} }
public override List<string> GetUserDataKeys() public override List<string> GetUserDataKeys()

View File

@ -21,7 +21,7 @@ namespace MediaBrowser.Controller.Entities
public TrailerType[] TrailerTypes { get; set; } public TrailerType[] TrailerTypes { get; set; }
public override double GetDefaultPrimaryImageAspectRatio() public override double GetDefaultPrimaryImageAspectRatio()
=> 2 / 3; => 2.0 / 3;
public override UnratedItem GetBlockUnratedType() public override UnratedItem GetBlockUnratedType()
{ {

View File

@ -54,11 +54,11 @@ namespace MediaBrowser.Controller.LiveTv
if (string.Equals(serviceName, EmbyServiceName, StringComparison.OrdinalIgnoreCase) || string.Equals(serviceName, "Next Pvr", StringComparison.OrdinalIgnoreCase)) if (string.Equals(serviceName, EmbyServiceName, StringComparison.OrdinalIgnoreCase) || string.Equals(serviceName, "Next Pvr", StringComparison.OrdinalIgnoreCase))
{ {
return 2 / 3; return 2.0 / 3;
} }
else else
{ {
return 16 / 9; return 16.0 / 9;
} }
} }