diff options
| author | Luke <luke.pulverenti@gmail.com> | 2016-12-13 13:27:53 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-12-13 13:27:53 -0500 |
| commit | 6cdbb25b9d756b58806414455cc4c4d1bc555217 (patch) | |
| tree | b6bc4f10ad1c6f758215a719b2be932b5979e896 /Emby.Server.Implementations/Security/AuthenticationRepository.cs | |
| parent | b33dcdf7bd61a8096928e1b2b5e34af1c8373096 (diff) | |
| parent | ffad9c27e4844eeab235f88cb45739370d22a83a (diff) | |
Merge pull request #2340 from MediaBrowser/dev
Dev
Diffstat (limited to 'Emby.Server.Implementations/Security/AuthenticationRepository.cs')
| -rw-r--r-- | Emby.Server.Implementations/Security/AuthenticationRepository.cs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Emby.Server.Implementations/Security/AuthenticationRepository.cs b/Emby.Server.Implementations/Security/AuthenticationRepository.cs index 392db6935..a2d61873b 100644 --- a/Emby.Server.Implementations/Security/AuthenticationRepository.cs +++ b/Emby.Server.Implementations/Security/AuthenticationRepository.cs @@ -206,15 +206,15 @@ namespace Emby.Server.Implementations.Security { using (var connection = CreateConnection(true)) { - var result = new QueryResult<AuthenticationInfo>(); - - connection.RunInTransaction(db => + return connection.RunInTransaction(db => { + var result = new QueryResult<AuthenticationInfo>(); + var statementTexts = new List<string>(); statementTexts.Add(commandText); statementTexts.Add("select count (Id) from AccessTokens" + whereTextWithoutPaging); - var statements = PrepareAllSafe(db, string.Join(";", statementTexts.ToArray())) + var statements = PrepareAllSafe(db, statementTexts) .ToList(); using (var statement = statements[0]) @@ -236,10 +236,10 @@ namespace Emby.Server.Implementations.Security } } - }, ReadTransactionMode); + result.Items = list.ToArray(); + return result; - result.Items = list.ToArray(); - return result; + }, ReadTransactionMode); } } } |
