From 06b89fec50e53edbd7ded6255dcb914401416300 Mon Sep 17 00:00:00 2001 From: jvyden Date: Sun, 10 Oct 2021 19:49:14 -0400 Subject: [PATCH] Change /filterResources to send back all resources --- ProjectLighthouse/Controllers/ResourcesController.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ProjectLighthouse/Controllers/ResourcesController.cs b/ProjectLighthouse/Controllers/ResourcesController.cs index 2bdfd3f4..d251e7ae 100644 --- a/ProjectLighthouse/Controllers/ResourcesController.cs +++ b/ProjectLighthouse/Controllers/ResourcesController.cs @@ -1,5 +1,6 @@ using System; using System.IO; +using System.Threading.Tasks; using Microsoft.AspNetCore.Mvc; using ProjectLighthouse.Serialization; using IOFile = System.IO.File; @@ -9,12 +10,16 @@ namespace ProjectLighthouse.Controllers { [Route("LITTLEBIGPLANETPS3_XML/")] [Produces("text/xml")] public class ResourcesController : ControllerBase { - [HttpPost("filterResources")] [HttpPost("showModerated")] public IActionResult ShowModerated() { return this.Ok(LbpSerializer.BlankElement("resources")); } + [HttpPost("filterResources")] + public async Task FilterResources() { + return this.Ok(await new StreamReader(Request.Body).ReadToEndAsync()); + } + [HttpGet("r/{hash}")] public IActionResult GetResource(string hash) { string path = Path.Combine(Environment.CurrentDirectory, "r", hash);