Remove scheme specifiers
This commit is contained in:
@@ -154,7 +154,7 @@ public class PostController(
|
||||
);
|
||||
|
||||
var fileUrl = Url.Action(nameof(PatchFileContent), "Post",
|
||||
new { postId = created.Post.Id, fileId = created.File.Id }, Request.Scheme
|
||||
new { postId = created.Post.Id, fileId = created.File.Id }
|
||||
);
|
||||
return CreatedAtAction(nameof(Get), new { id = created.Post.Id },
|
||||
PostDto.FromPost(created.Post, fileUrl));
|
||||
@@ -319,7 +319,7 @@ public class PostController(
|
||||
var entry = await postService.GetById(id);
|
||||
if (entry == null) return NotFound();
|
||||
var fileUrl = Url.Action(nameof(PatchFileContent), "Post",
|
||||
new { postId = entry.Id, fileId = entry.File.Id }, Request.Scheme
|
||||
new { postId = entry.Id, fileId = entry.File.Id }
|
||||
);
|
||||
return Ok(PostDto.FromPost(entry, fileUrl));
|
||||
}
|
||||
@@ -340,7 +340,7 @@ public class PostController(
|
||||
var newItems = list.Items.Select(i =>
|
||||
{
|
||||
var fileUrl = Url.Action(nameof(PatchFileContent), "Post",
|
||||
new { postId = i.Id, fileId = i.File.Id }, Request.Scheme
|
||||
new { postId = i.Id, fileId = i.File.Id }
|
||||
);
|
||||
return PostDto.FromPost(i, fileUrl);
|
||||
}).ToList();
|
||||
@@ -433,7 +433,7 @@ public class PostController(
|
||||
|
||||
var updated = await postService.Update(post);
|
||||
var fileUrl = Url.Action(nameof(PatchFileContent), "Post",
|
||||
new { postId = updated.Id, fileId = updated.File.Id }, Request.Scheme
|
||||
new { postId = updated.Id, fileId = updated.File.Id }
|
||||
);
|
||||
return Ok(PostDto.FromPost(updated, fileUrl));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user