for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Spatie\Analytics\Exceptions;
use DateTime;
use Exception;
class InvalidPeriod extends Exception
{
public static function startDateCannotBeAfterEndDate(DateTime $startDate, DateTime $endDate)
return new static("Start date `{$startDate->format('Y-m-d')}` cannot be after end date `{$endDate->format('Y-m-d')}`.");
}