Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,6 @@ rcf/

# Windows Store app package directories and files
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt
*.appx
Expand Down
6 changes: 3 additions & 3 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project>
<Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
Expand All @@ -17,7 +17,6 @@
<PackageVersion Include="Ardalis.Specification" Version="9.3.1" />
<PackageVersion Include="Ardalis.Specification.EntityFrameworkCore" Version="9.3.1" />
<PackageVersion Include="AutoMapper" Version="16.2.0" />
<PackageVersion Include="BuildBundlerMinifier" Version="3.2.449" />
<PackageVersion Include="coverlet.collector" Version="10.0.1" />
<PackageVersion Include="coverlet.msbuild" Version="10.0.1">
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
Expand All @@ -35,7 +34,8 @@
<PackageVersion Include="GoogleReCaptcha.V3" Version="1.3.1" />
<PackageVersion Include="Markdig" Version="1.3.2" />
<PackageVersion Include="MediaInfo.Wrapper.Core" Version="21.9.3" />
<PackageVersion Include="MediatR" Version="14.2.0" />
<PackageVersion Include="Mediator.Abstractions" Version="3.0.2" />
<PackageVersion Include="Mediator.SourceGenerator" Version="3.0.2" />
<PackageVersion Include="Microsoft.Extensions.Http.Resilience" Version="10.2.0" />
<PackageVersion Include="Microsoft.Extensions.ServiceDiscovery" Version="10.2.0" />
<PackageVersion Include="OpenTelemetry.Exporter.OpenTelemetryProtocol" Version="1.15.0" />
Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Core/DevBetterWeb.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<PackageReference Include="Ardalis.SmartEnum" />
<PackageReference Include="Ardalis.Specification" />
<PackageReference Include="CSharpFunctionalExtensions" />
<PackageReference Include="MediatR" />
<PackageReference Include="Mediator.Abstractions" />
<PackageReference Include="Microsoft.ApplicationInsights.AspNetCore" />
<PackageReference Include="Microsoft.Extensions.Identity.Core" />
<PackageReference Include="NimblePros.Vimeo" />
Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Core/Events/AppStartedEvent.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using DevBetterWeb.Core.SharedKernel;
using MediatR;
using Mediator;

namespace DevBetterWeb.Core.Events;

Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Core/Interfaces/IHandle.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using System.Threading.Tasks;
using DevBetterWeb.Core.Events;
using DevBetterWeb.Core.SharedKernel;
using MediatR;
using Mediator;

namespace DevBetterWeb.Core.Interfaces;

Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Core/SharedKernel/BaseDomainEvent.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using MediatR;
using Mediator;

namespace DevBetterWeb.Core.SharedKernel;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<ItemGroup>
<PackageReference Include="Ardalis.Specification.EntityFrameworkCore" />
<PackageReference Include="Markdig" />
<PackageReference Include="MediatR" />
<PackageReference Include="Mediator.Abstractions" />
<PackageReference Include="NimblePros.Vimeo" />
<PackageReference Include="Ardalis.EFCore.Extensions" />
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using System.Threading.Tasks;
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Core.SharedKernel;
using MediatR;
using Mediator;

namespace DevBetterWeb.Infrastructure.DomainEvents;

Expand All @@ -17,7 +17,7 @@ public DomainEventHandler(IEnumerable<IHandle<TDomainEvent>> handlers)
_handlers = handlers;
}

public async Task Handle(TDomainEvent notification, CancellationToken cancellationToken)
public async ValueTask Handle(TDomainEvent notification, CancellationToken cancellationToken)
{
foreach (var handler in _handlers)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,17 @@
using System.Threading.Tasks;
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Core.SharedKernel;
using MediatR;
using Mediator;
using Microsoft.Extensions.Logging;

namespace DevBetterWeb.Infrastructure.DomainEvents;

public class MediatRDomainEventDispatcher : IDomainEventDispatcher
public class MediatorDomainEventDispatcher : IDomainEventDispatcher
{
private readonly IMediator _mediator;
private readonly ILogger<MediatRDomainEventDispatcher> _logger;
private readonly ILogger<MediatorDomainEventDispatcher> _logger;

public MediatRDomainEventDispatcher(IMediator mediator, ILogger<MediatRDomainEventDispatcher> logger)
public MediatorDomainEventDispatcher(IMediator mediator, ILogger<MediatorDomainEventDispatcher> logger)
{
_mediator = mediator;
_logger = logger;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using DevBetterWeb.Core.Events;
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Infrastructure.DiscordWebooks;
using MediatR;
using Mediator;

namespace DevBetterWeb.Core.Handlers;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public static IServiceCollection AddInfrastructureServices(this IServiceCollecti
}

// Common Dependencies
services.AddScoped<IDomainEventDispatcher,MediatRDomainEventDispatcher>();
services.AddScoped<IDomainEventDispatcher, MediatorDomainEventDispatcher>();
// services.AddScoped<IDomainEventDispatcher>(sp => sp.GetRequiredService<DomainEventDispatcher>());

services.AddScoped<IMemberRegistrationService, MemberRegistrationService>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using DevBetterWeb.Core.Exceptions;
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Infrastructure.Identity.Data;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Identity;
using Microsoft.EntityFrameworkCore;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using DevBetterWeb.Core.Exceptions;
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Infrastructure.Identity.Data;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Identity;
using Microsoft.EntityFrameworkCore;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using DevBetterWeb.Core.Events;
using DevBetterWeb.Infrastructure.DomainEvents;
using DevBetterWeb.Infrastructure.Identity.Data;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Identity;
using Microsoft.AspNetCore.Identity.UI.Services;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Infrastructure.Identity.Data;
using GoogleReCaptcha.V3.Interface;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Identity;
using Microsoft.AspNetCore.Mvc;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Infrastructure.Identity.Data;
using GoogleReCaptcha.V3.Interface;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Identity;
using Microsoft.AspNetCore.Mvc;
Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Web/Controllers/HomeController.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using DevBetterWeb.Core.Events;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Diagnostics;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Mvc;
Expand Down
7 changes: 5 additions & 2 deletions src/DevBetterWeb.Web/DevBetterWeb.Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,14 @@
<PackageReference Include="Ardalis.ApiEndpoints" />
<PackageReference Include="Ardalis.ListStartupServices" />
<PackageReference Include="Ardalis.SmartEnum" />
<PackageReference Include="BuildBundlerMinifier" />
<PackageReference Include="CSharpFunctionalExtensions" />
<PackageReference Include="Dapper" />
<PackageReference Include="GoogleReCaptcha.V3" />
<PackageReference Include="MediatR" />
<PackageReference Include="Mediator.Abstractions" />
<PackageReference Include="Mediator.SourceGenerator">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.ApplicationInsights.AspNetCore" />
<PackageReference Include="Microsoft.AspNetCore.AzureAppServices.HostingStartup" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Core.Specs;
using DevBetterWeb.Infrastructure.Identity.Data;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Identity;
Expand Down
4 changes: 2 additions & 2 deletions src/DevBetterWeb.Web/Pages/_MemberLayout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<link href="/css/dark-mode.css" rel="stylesheet" />

<!-- Custom styles for this template-->
<link href="~/css/sb-admin-2.min.css" rel="stylesheet">
<link href="~/css/sb-admin-2.css" rel="stylesheet">
@await RenderSectionAsync("head", required: false).ConfigureAwait(false)
</head>

Expand Down Expand Up @@ -293,7 +293,7 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.1/umd/popper.min.js"
asp-fallback-src="~/lib/popperJs/umd/popper.min.js">
</script>
<script src="~/js/site.min.js" asp-append-version="true"></script>
<script src="~/js/site.js" asp-append-version="true"></script>
</environment>
<script src="~/js/jquery.twbsPagination.min.js" asp-append-version="true"></script>
<script type="text/javascript" charset="utf8" src="https://cdn.datatables.net/1.10.20/js/jquery.dataTables.js"></script>
Expand Down
14 changes: 9 additions & 5 deletions src/DevBetterWeb.Web/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,15 @@

builder.Services.AddInfrastructureServices(isDevelopment, vimeoToken);

builder.Services.AddMediatR(cfg =>
cfg.RegisterServicesFromAssemblies(
typeof(IAggregateRoot).Assembly,
typeof(AppDbContext).Assembly,
typeof(Program).Assembly));
builder.Services.AddMediator(options =>
{
options.Assemblies =
[
typeof(IAggregateRoot),
typeof(AppDbContext),
typeof(Program)
];
});

builder.Services.AddScoped(typeof(IRepository<>), typeof(EfRepository<>));

Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Web/Services/DailyCheckService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using DevBetterWeb.Core.Events;
using DevBetterWeb.Core.Interfaces;
using DevBetterWeb.Core.Specs;
using MediatR;
using Mediator;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Logging;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using System.Threading.Tasks;
using DevBetterWeb.Core.Events;
using DevBetterWeb.Core.Interfaces;
using MediatR;
using Mediator;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Logging;

Expand Down
2 changes: 1 addition & 1 deletion src/DevBetterWeb.Web/Views/Shared/_Layout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@
asp-fallback-src="~/lib/bootstrap/dist/js/bootstrap.min.js"
asp-fallback-test="window.jQuery && window.jQuery.fn && window.jQuery.fn.modal">
</script>
<script src="~/js/site.min.js" asp-append-version="true"></script>
<script src="~/js/site.js" asp-append-version="true"></script>
</environment>
<script src="~/js/jquery.twbsPagination.min.js" asp-append-version="true"></script>
<script type="text/javascript" charset="utf8" src="https://cdn.datatables.net/1.10.20/js/jquery.dataTables.js"></script>
Expand Down
24 changes: 0 additions & 24 deletions src/DevBetterWeb.Web/bundleconfig.json

This file was deleted.

5 changes: 0 additions & 5 deletions src/DevBetterWeb.Web/wwwroot/css/landing-page.min.css

This file was deleted.

12 changes: 0 additions & 12 deletions src/DevBetterWeb.Web/wwwroot/css/sb-admin-2.min.css

This file was deleted.

1 change: 0 additions & 1 deletion src/DevBetterWeb.Web/wwwroot/css/site.min.css

This file was deleted.

1 change: 0 additions & 1 deletion src/DevBetterWeb.Web/wwwroot/js/site.min.js

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using DevBetterWeb.Web;
using DevBetterWeb.Web.Areas.Identity;
using DevBetterWeb.Web.Models;
using MediatR;
using Mediator;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Identity;
using Microsoft.AspNetCore.Mvc.Testing;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="MediatR" />
<PackageReference Include="Mediator.Abstractions" />
<PackageReference Include="Microsoft.Extensions.Identity.Core" />
<PackageReference Include="Microsoft.NET.Test.Sdk" />
<PackageReference Include="xunit" />
Expand Down
Loading
Loading