Skip to content

Commit 9d85026

Browse files
committed
Replace Carbon type hinting by CarbonInterface
1 parent da89010 commit 9d85026

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ Almost every configuration value can be overrided dynamically by methods.
380380
- getSerialNumber() - returns formatted serial number
381381

382382
#### Date
383-
- date(Carbon)
383+
- date(CarbonInterface)
384384
- dateFormat(string) - Carbon format of date
385385
- payUntilDays(int) - Days payment due since invoice issued
386386
- getDate() - returns formatted date

src/Traits/DateFormatter.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
namespace LaravelDaily\Invoices\Traits;
44

5-
use Carbon\Carbon;
5+
use Carbon\CarbonInterface;
66

77
/**
88
* Trait DateFormatter
99
*/
1010
trait DateFormatter
1111
{
1212
/**
13-
* @var Carbon
13+
* @var CarbonInterface
1414
*/
1515
public $date;
1616

@@ -25,10 +25,10 @@ trait DateFormatter
2525
public $pay_until_days;
2626

2727
/**
28-
* @param Carbon $date
28+
* @param CarbonInterface $date
2929
* @return $this
3030
*/
31-
public function date(Carbon $date)
31+
public function date(CarbonInterface $date)
3232
{
3333
$this->date = $date;
3434

0 commit comments

Comments
 (0)