public function is_discussion_locked(discussion_entity $discussion) : bool {
        if ($discussion->is_locked()) {
            return true;
        }

        return $this->is_discussion_time_locked($discussion);
    }