Get all posts
This commit is contained in:
parent
2c7ccae412
commit
d2080679fd
3 changed files with 13 additions and 3 deletions
|
@ -97,8 +97,8 @@ namespace Robware.Api.Blog.Controllers {
|
|||
}
|
||||
}
|
||||
|
||||
//[HttpGet]
|
||||
//Task<IEnumerable<BlogPost>> GetAllPosts();
|
||||
[HttpGet(nameof(GetAllPosts))]
|
||||
public async Task<ActionResult<BlogPost[]>> GetAllPosts() => (await _blogRepository.GetAllPostsAsync()).ToArray();
|
||||
|
||||
//[HttpGet]
|
||||
//Task DeletePost(int id);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue