update request classes

This commit is contained in:
Luke Pulverenti
2017-09-03 14:38:26 -04:00
parent 2084678266
commit 504f56d841
12 changed files with 47 additions and 97 deletions

View File

@@ -43,7 +43,7 @@ namespace MediaBrowser.Api.System
/// Class RestartApplication
/// </summary>
[Route("/System/Restart", "POST", Summary = "Restarts the application, if needed")]
[Authenticated(Roles = "Admin")]
[Authenticated(Roles = "Admin", AllowLocal = true)]
public class RestartApplication
{
}
@@ -52,10 +52,9 @@ namespace MediaBrowser.Api.System
/// This is currently not authenticated because the uninstaller needs to be able to shutdown the server.
/// </summary>
[Route("/System/Shutdown", "POST", Summary = "Shuts down the application")]
[Authenticated(Roles = "Admin", AllowLocal = true)]
public class ShutdownApplication
{
// TODO: This is not currently authenticated due to uninstaller
// Improve later
}
[Route("/System/Logs", "GET", Summary = "Gets a list of available server log files")]
@@ -126,7 +125,7 @@ namespace MediaBrowser.Api.System
}
catch (IOException)
{
files = new FileSystemMetadata[]{};
files = new FileSystemMetadata[] { };
}
var result = files.Select(i => new LogFile