mirror of
https://github.com/Jackett/Jackett.git
synced 2025-09-17 17:34:09 +02:00
Convert functions and properties to expression bodies when able (#7312)
Convert functions and properties to expression bodies when able
This commit is contained in:
@@ -25,10 +25,7 @@ namespace Jackett.Server.Controllers
|
||||
{
|
||||
public IServerService serverService;
|
||||
|
||||
public RequiresApiKey(IServerService ss)
|
||||
{
|
||||
serverService = ss;
|
||||
}
|
||||
public RequiresApiKey(IServerService ss) => serverService = ss;
|
||||
|
||||
public void OnActionExecuting(ActionExecutingContext context)
|
||||
{
|
||||
@@ -433,10 +430,7 @@ namespace Jackett.Server.Controllers
|
||||
}
|
||||
|
||||
[Route("[action]/{ignored?}")]
|
||||
public IActionResult GetErrorXML(int code, string description)
|
||||
{
|
||||
return Content(CreateErrorXML(code, description), "application/xml", Encoding.UTF8);
|
||||
}
|
||||
public IActionResult GetErrorXML(int code, string description) => Content(CreateErrorXML(code, description), "application/xml", Encoding.UTF8);
|
||||
|
||||
public static string CreateErrorXML(int code, string description)
|
||||
{
|
||||
|
Reference in New Issue
Block a user