chore(codebase): full cleanup pass
This commit is contained in:
@@ -45,12 +45,12 @@ public class ChangePresentationInfosHandler(
|
||||
ChangePresentationInfosRequest request,
|
||||
CancellationToken ct)
|
||||
{
|
||||
var creator = await context
|
||||
Creator? creator = await context
|
||||
.Creators
|
||||
.Include(c => c.Presentation)
|
||||
.SingleOrDefaultAsync(
|
||||
c => c.Id == request.CreatorId,
|
||||
cancellationToken: ct);
|
||||
ct);
|
||||
|
||||
if (creator is null)
|
||||
{
|
||||
@@ -60,12 +60,12 @@ public class ChangePresentationInfosHandler(
|
||||
|
||||
// Update the presentation info with the new values
|
||||
creator.Presentation.Description = request.Description.Trim();
|
||||
creator.Presentation.VideoUrl = request.VideoUrl != null
|
||||
creator.Presentation.VideoUrl = request.VideoUrl != null
|
||||
? YouTubeUrlHelper.ExtractVideoId(request.VideoUrl.Trim())
|
||||
: null;
|
||||
|
||||
|
||||
await context.SaveChangesAsync(ct);
|
||||
|
||||
|
||||
await SendOkAsync(ct);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user