using Mango.Nop.Services;
using Nop.Core.Domain.Customers;

namespace Nop.Plugin.Misc.AuctionPlugin.Services;

public class SessionService : MgSessionService<SessionItem>, ISessionService
{
    public bool TryGetSessionItemByCustomerId(int customerId, out SessionItem sessionItem)
    {
        sessionItem = Sessions.Values.FirstOrDefault(x => x.CustomerId == customerId);
        return sessionItem != null;
    }
}