<?php

namespace App\Repositories;

use App\Models\Subscription;

class SubscriptionRepository extends BaseRepository
{
    public function __construct(Subscription $model)
    {
        parent::__construct($model);
    }

    public function getActiveUserSubscription($userId)
    {
        return $this->model->where('user_id', $userId)
            ->where('is_active', true)
            ->first();
    }
}
