<?php

namespace Modules\Shared\Helpers;

use Carbon\Carbon;

class UtilsHandler
{

    public function getFirstAndLastDayOfMonth($anio, $mes) : array
    {
        $dateStart      = Carbon::createFromDate($anio, $mes, 1);
        $dateEnd        = $dateStart->copy()->addMonth(1)->subDay();
        $rangoFechas    = [$dateStart->format('Y-m-d'), $dateEnd->format('Y-m-d')];
        return $rangoFechas;
    }
    
}