Minor improvements
This commit is contained in:
parent
b76f570583
commit
a73e1f18b6
|
@ -242,11 +242,11 @@ namespace MediaBrowser.Api.UserLibrary
|
||||||
return folder.GetItems(GetItemsQuery(request, dtoOptions, user));
|
return folder.GetItems(GetItemsQuery(request, dtoOptions, user));
|
||||||
}
|
}
|
||||||
|
|
||||||
var itemsArray = folder.GetChildren(user, true).ToArray();
|
var itemsArray = folder.GetChildren(user, true);
|
||||||
return new QueryResult<BaseItem>
|
return new QueryResult<BaseItem>
|
||||||
{
|
{
|
||||||
Items = itemsArray,
|
Items = itemsArray,
|
||||||
TotalRecordCount = itemsArray.Length,
|
TotalRecordCount = itemsArray.Count,
|
||||||
StartIndex = 0
|
StartIndex = 0
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -2741,7 +2741,7 @@ namespace MediaBrowser.Controller.Entities
|
||||||
{
|
{
|
||||||
var list = GetEtagValues(user);
|
var list = GetEtagValues(user);
|
||||||
|
|
||||||
return string.Join("|", list.ToArray()).GetMD5().ToString("N", CultureInfo.InvariantCulture);
|
return string.Join("|", list).GetMD5().ToString("N", CultureInfo.InvariantCulture);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected virtual List<string> GetEtagValues(User user)
|
protected virtual List<string> GetEtagValues(User user)
|
||||||
|
@ -2784,8 +2784,7 @@ namespace MediaBrowser.Controller.Entities
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
var view = this as IHasCollectionType;
|
if (this is IHasCollectionType view)
|
||||||
if (view != null)
|
|
||||||
{
|
{
|
||||||
if (string.Equals(view.CollectionType, CollectionType.LiveTv, StringComparison.OrdinalIgnoreCase))
|
if (string.Equals(view.CollectionType, CollectionType.LiveTv, StringComparison.OrdinalIgnoreCase))
|
||||||
{
|
{
|
||||||
|
|
|
@ -864,7 +864,7 @@ namespace MediaBrowser.Controller.Entities
|
||||||
return SortItemsByRequest(query, result);
|
return SortItemsByRequest(query, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
return result.ToArray();
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
return GetItemsInternal(query).Items;
|
return GetItemsInternal(query).Items;
|
||||||
|
|
|
@ -478,7 +478,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
_logger.LogError(ex, "I-frame image extraction failed, will attempt standard way. Input: {arguments}", inputArgument);
|
_logger.LogError(ex, "I-frame image extraction failed, will attempt standard way. Input: {Arguments}", inputArgument);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -969,7 +969,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||||
|
|
||||||
public int? ExitCode { get; private set; }
|
public int? ExitCode { get; private set; }
|
||||||
|
|
||||||
void OnProcessExited(object sender, EventArgs e)
|
private void OnProcessExited(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
var process = (Process)sender;
|
var process = (Process)sender;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user