13 lines
312 B
C#
13 lines
312 B
C#
using MediatR;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
|
namespace AutobusApi.Api.Controllers;
|
|
|
|
[ApiController]
|
|
[Route("[controller]")]
|
|
public class BaseController : ControllerBase
|
|
{
|
|
private IMediator _mediator;
|
|
protected IMediator Mediator => _mediator ??= HttpContext.RequestServices.GetService<IMediator>();
|
|
}
|