<?php

namespace App\Http\Controllers\Admin\Setting;

use App\Http\Controllers\Controller;
use App\Services\Core\Setting\DeliverySettingService;
use Illuminate\Http\Request;

class MailCheckController extends Controller
{
    public function __construct(DeliverySettingService $service)
    {
        $this->service = $service;
    }
    public function __invoke(Request $request)
    {
        return count($this->service->getCachedMailSettings()) ? 1 : 0;
    }
}