<?php

namespace App\Classes\Modules\Currencies\Standards\Rules\Rates;

use App\Classes\General\Abstracts\AbstractRule;
use App\Classes\Modules\Currencies\DataTransferObjects\CurrencyObject;

class CanListRates extends AbstractRule
{
    /**
     * @return bool
     */
    protected function authorized(): bool
    {
        // TODO  Set Authorization rules

        if (!\Auth::user()->can('view currency_rate')) {
            return false;
        }

        return true;

    }

    /**
     * @param CurrencyObject $object
     * @return bool
     */
    protected function validators($object): bool
    {
        return true;

    }


    /**
     * @param CurrencyObject $object
     * @return bool
     */
    protected function criteria($object): bool
    {
        return true;
    }

}