aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Model')
-rw-r--r--MediaBrowser.Model/Configuration/ServerConfiguration.cs8
-rw-r--r--MediaBrowser.Model/Querying/QueryResult.cs6
2 files changed, 11 insertions, 3 deletions
diff --git a/MediaBrowser.Model/Configuration/ServerConfiguration.cs b/MediaBrowser.Model/Configuration/ServerConfiguration.cs
index b8abe49e3..9de6fef61 100644
--- a/MediaBrowser.Model/Configuration/ServerConfiguration.cs
+++ b/MediaBrowser.Model/Configuration/ServerConfiguration.cs
@@ -172,16 +172,18 @@ namespace MediaBrowser.Model.Configuration
if (string.IsNullOrWhiteSpace(value))
{
// If baseUrl is empty, set an empty prefix string
- value = string.Empty;
+ _baseUrl = string.Empty;
+ return;
}
- else if (!value.StartsWith("/"))
+
+ if (value[0] != '/')
{
// If baseUrl was not configured with a leading slash, append one for consistency
value = "/" + value;
}
// Normalize the end of the string
- if (value.EndsWith("/"))
+ if (value[value.Length - 1] == '/')
{
// If baseUrl was configured with a trailing slash, remove it for consistency
value = value.Remove(value.Length - 1);
diff --git a/MediaBrowser.Model/Querying/QueryResult.cs b/MediaBrowser.Model/Querying/QueryResult.cs
index c007a45d6..221645afb 100644
--- a/MediaBrowser.Model/Querying/QueryResult.cs
+++ b/MediaBrowser.Model/Querying/QueryResult.cs
@@ -17,6 +17,12 @@ namespace MediaBrowser.Model.Querying
/// <value>The total record count.</value>
public int TotalRecordCount { get; set; }
+ /// <summary>
+ /// The index of the first record in Items.
+ /// </summary>
+ /// <value>First record index.</value>
+ public int StartIndex { get; set; }
+
public QueryResult()
{
Items = Array.Empty<T>();