Skip to content

Commit e8396e4

Browse files
authored
Merge pull request #110 from gothinkster/updates
Updates
2 parents 5f76a4c + 1b7f1d7 commit e8396e4

File tree

25 files changed

+139
-528
lines changed

25 files changed

+139
-528
lines changed

.config/dotnet-tools.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"isRoot": true,
44
"tools": {
55
"csharpier": {
6-
"version": "0.27.3",
6+
"version": "0.28.0",
77
"commands": [
88
"dotnet-csharpier"
99
]

.github/workflows/dotnetcore.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@ jobs:
1111
- uses: actions/checkout@v4
1212
- uses: actions/setup-dotnet@v4
1313
with:
14-
dotnet-version: 8.0.201
14+
dotnet-version: 8.0.204
1515
- run: dotnet run --project build/build.csproj

Directory.Packages.props

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
<PackageVersion Include="AutoMapper" Version="13.0.1" />
44
<PackageVersion Include="Bullseye" Version="5.0.0" />
55
<PackageVersion Include="Glob" Version="1.1.9" />
6-
<PackageVersion Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="8.0.2" />
7-
<PackageVersion Include="Microsoft.EntityFrameworkCore.InMemory" Version="8.0.2" />
8-
<PackageVersion Include="Microsoft.EntityFrameworkCore.Sqlite" Version="8.0.2" />
9-
<PackageVersion Include="Microsoft.EntityFrameworkCore.SqlServer" Version="8.0.2" />
6+
<PackageVersion Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="8.0.4" />
7+
<PackageVersion Include="Microsoft.EntityFrameworkCore.InMemory" Version="8.0.4" />
8+
<PackageVersion Include="Microsoft.EntityFrameworkCore.Sqlite" Version="8.0.4" />
9+
<PackageVersion Include="Microsoft.EntityFrameworkCore.SqlServer" Version="8.0.4" />
1010
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
1111
<PackageVersion Include="Serilog" Version="3.1.1" />
1212
<PackageVersion Include="Serilog.Extensions.Logging" Version="8.0.0" />

src/Conduit/Domain/Person.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
using System;
21
using System.Collections.Generic;
32
using System.Text.Json.Serialization;
43

src/Conduit/Features/Articles/Create.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,15 +60,15 @@ CancellationToken cancellationToken
6060
var t = await context.Tags.FindAsync(tag);
6161
if (t == null)
6262
{
63-
t = new Tag() { TagId = tag };
63+
t = new Tag { TagId = tag };
6464
await context.Tags.AddAsync(t, cancellationToken);
6565
//save immediately for reuse
6666
await context.SaveChangesAsync(cancellationToken);
6767
}
6868
tags.Add(t);
6969
}
7070

71-
var article = new Article()
71+
var article = new Article
7272
{
7373
Author = author,
7474
Body = message.Article.Body,
@@ -81,7 +81,7 @@ CancellationToken cancellationToken
8181
await context.Articles.AddAsync(article, cancellationToken);
8282

8383
await context.ArticleTags.AddRangeAsync(
84-
tags.Select(x => new ArticleTag() { Article = article, Tag = x }),
84+
tags.Select(x => new ArticleTag { Article = article, Tag = x }),
8585
cancellationToken
8686
);
8787

src/Conduit/Features/Articles/Edit.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,11 +109,11 @@ IEnumerable<string> articleTagList
109109
var at = article.ArticleTags?.FirstOrDefault(t => t.TagId == tag);
110110
if (at == null)
111111
{
112-
at = new ArticleTag()
112+
at = new ArticleTag
113113
{
114114
Article = article,
115115
ArticleId = article.ArticleId,
116-
Tag = new Tag() { TagId = tag },
116+
Tag = new Tag { TagId = tag },
117117
TagId = tag
118118
};
119119
articleTagsToCreate.Add(at);

src/Conduit/Features/Articles/List.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
using System.Net;
33
using System.Threading;
44
using System.Threading.Tasks;
5-
using Conduit.Domain;
65
using Conduit.Infrastructure;
76
using Conduit.Infrastructure.Errors;
87
using MediatR;
@@ -111,11 +110,7 @@ CancellationToken cancellationToken
111110
.AsNoTracking()
112111
.ToListAsync(cancellationToken);
113112

114-
return new ArticlesEnvelope()
115-
{
116-
Articles = articles,
117-
ArticlesCount = queryable.Count()
118-
};
113+
return new ArticlesEnvelope { Articles = articles, ArticlesCount = queryable.Count() };
119114
}
120115
}
121116
}

src/Conduit/Features/Comments/Create.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ CancellationToken cancellationToken
4949
cancellationToken
5050
);
5151

52-
var comment = new Comment()
52+
var comment = new Comment
5353
{
5454
Author = author,
5555
Body = message.Model.Comment.Body ?? string.Empty,

src/Conduit/Features/Favorites/Add.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ CancellationToken cancellationToken
6161

6262
if (favorite == null)
6363
{
64-
favorite = new ArticleFavorite()
64+
favorite = new ArticleFavorite
6565
{
6666
Article = article,
6767
ArticleId = article.ArticleId,

src/Conduit/Features/Followers/Add.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ CancellationToken cancellationToken
6464

6565
if (followedPeople == null)
6666
{
67-
followedPeople = new FollowedPeople()
67+
followedPeople = new FollowedPeople
6868
{
6969
Observer = observer,
7070
ObserverId = observer.PersonId,

0 commit comments

Comments
 (0)