using Microsoft.AspNetCore.Mvc;
using System.Security.Claims;

namespace planli.backend.Controllers
{
    public class BaseController : ControllerBase
    {
        protected int GetCurrentUserId()
        {
            return int.Parse(User.FindFirstValue(ClaimTypes.NameIdentifier)!);
        }
    }
}