fix: preserve blank CVs and reliable editor undo
This commit is contained in:
@@ -240,6 +240,7 @@ public sealed class CvVariantController : ControllerBase
|
||||
{
|
||||
var render = await _variants.RenderAsync(user.Id, id, Person(user), ct, expectedVersion);
|
||||
if (render is null) return NotFound();
|
||||
if (!render.HasContent) return BadRequest(new { code = "cv_empty_content" });
|
||||
var artifact = await _pdf.ExportAsync(user.Id, new TailoredCvRenderResult(render.ThemeId, render.SuggestedFileName, render.Html), ct);
|
||||
return File(artifact.Bytes, "application/pdf", artifact.FileName);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user