diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2017-08-09 15:56:38 -0400 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2017-08-09 15:56:38 -0400 |
| commit | 40442f887ba717ae47620b152315f21b252fe049 (patch) | |
| tree | 340be082fd2296f19aed17b24b22b5095e3815a7 /Emby.Server.Implementations/Security/AuthenticationRepository.cs | |
| parent | 52aeb3c40b3e2f0fdc377ac7c793714add2be0ef (diff) | |
consolidate emby.server.core into emby.server.implementations
Diffstat (limited to 'Emby.Server.Implementations/Security/AuthenticationRepository.cs')
| -rw-r--r-- | Emby.Server.Implementations/Security/AuthenticationRepository.cs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/Emby.Server.Implementations/Security/AuthenticationRepository.cs b/Emby.Server.Implementations/Security/AuthenticationRepository.cs index 9ec0af6bb..d512ff4fb 100644 --- a/Emby.Server.Implementations/Security/AuthenticationRepository.cs +++ b/Emby.Server.Implementations/Security/AuthenticationRepository.cs @@ -11,6 +11,7 @@ using MediaBrowser.Controller.Security; using MediaBrowser.Model.Logging; using MediaBrowser.Model.Querying; using SQLitePCL.pretty; +using MediaBrowser.Model.Extensions; namespace Emby.Server.Implementations.Security { @@ -174,13 +175,13 @@ namespace Emby.Server.Implementations.Security var whereTextWithoutPaging = whereClauses.Count == 0 ? string.Empty : - " where " + string.Join(" AND ", whereClauses.ToArray()); + " where " + string.Join(" AND ", whereClauses.ToArray(whereClauses.Count)); if (startIndex > 0) { var pagingWhereText = whereClauses.Count == 0 ? string.Empty : - " where " + string.Join(" AND ", whereClauses.ToArray()); + " where " + string.Join(" AND ", whereClauses.ToArray(whereClauses.Count)); whereClauses.Add(string.Format("Id NOT IN (SELECT Id FROM AccessTokens {0} ORDER BY DateCreated LIMIT {1})", pagingWhereText, @@ -189,7 +190,7 @@ namespace Emby.Server.Implementations.Security var whereText = whereClauses.Count == 0 ? string.Empty : - " where " + string.Join(" AND ", whereClauses.ToArray()); + " where " + string.Join(" AND ", whereClauses.ToArray(whereClauses.Count)); commandText += whereText; @@ -236,7 +237,7 @@ namespace Emby.Server.Implementations.Security } } - result.Items = list.ToArray(); + result.Items = list.ToArray(list.Count); return result; }, ReadTransactionMode); |
