Hi Demis, I like the new forum. Certainly makes reading code easier
I am having an issue whereby I can’t get uploads to show in Request.Files … it’s always empty.
I am using 4.0.39 with the code I had previously used here. I have tried Chrome, Safari and Postman, same result.
using System;
using ServiceStack;
namespace Testv4
{
class MainClass
{
public static void Main()
{
var appHost = new AppHost(500);
appHost.Init();
appHost.Start("http://*:8082/");
Console.ReadKey();
}
}
public class TestApp
{
[Route("/upload", "POST")]
public class UploadFileRequest {}
public class TestController : Service
{
public void Any(UploadFileRequest request)
{
Console.WriteLine(Request.Files.Length); // Always 0
}
}
}
public class AppHost : AppHostHttpListenerPoolBase
{
public AppHost(int poolSize) : base("Test Service", poolSize, typeof(TestApp).Assembly)
{
}
public override void Configure(Funq.Container container)
{
}
}
}