<?php

namespace App\Modules\Question\Application;

use App\Modules\Question\Domain\Question;
use App\Modules\Question\Domain\QuestionRepository;

class QuestionUpdater {

    private QuestionRepository $repository;
    public function __construct(QuestionRepository $repository) {
        $this->repository = $repository;
    }

    public function __invoke (Question $question) {
        return $this->repository->update($question);
    }
}