Open christophdebaene opened 6 months ago
@christophdebaene Hi, did you find the solution?
For me the problem was in:
[Authorize(Policy = IdentityPolicies.AccountsCreateUsersPolicy)]
[ProducesResponseType(typeof(List<CompositeItemOutDto>), StatusCodes.Status200OK)]
[HttpGet("GetCategoriesAllTranslations")]
public IActionResult GetCategoriesAllTranslations()
{
...
var result = someSvc.GetOutDtosAsync(TenantId);
return Ok(result);
}
So in ProducesResponseType - there is List
public async Task<IActionResult> GetCategoriesAllTranslations()
{
...
var result = await someSvc.GetOutDtosAsync(TenantId);
return Ok(result);
}
I get an error when calling
ToJson
. I don't understand why it works fine when the type is simply Customer, but I encounter an error when it's a list.