File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -34,9 +34,7 @@ public function boot()
34
34
*/
35
35
public function register ()
36
36
{
37
- $ this ->app ->singleton ('zodiac ' , function (Application $ app ) {
38
- return new ZodiacBridge ($ app );
39
- });
37
+ $ this ->app ->singleton ('zodiac ' , fn (Application $ app ): ZodiacBridge => new ZodiacBridge ($ app ));
40
38
}
41
39
42
40
/**
Original file line number Diff line number Diff line change 9
9
use Intervention \Zodiac \Exceptions \RuntimeException ;
10
10
use Intervention \Zodiac \Interfaces \ZodiacInterface ;
11
11
use Intervention \Zodiac \Zodiacs \Capricorn ;
12
+ use Stringable ;
12
13
13
- class ZodiacComparableDate
14
+ class ZodiacComparableDate implements Stringable
14
15
{
15
16
/**
16
17
* Create new instance
@@ -60,7 +61,11 @@ public function isZodiac(ZodiacInterface $zodiac): bool
60
61
->addDay ()
61
62
];
62
63
63
- return ($ this ->date ->between (...$ period1 ) || $ this ->date ->between (...$ period2 ));
64
+ if ($ this ->date ->between (...$ period1 )) {
65
+ return true ;
66
+ }
67
+
68
+ return $ this ->date ->between (...$ period2 );
64
69
}
65
70
66
71
return $ this ->date ->between (
You can’t perform that action at this time.
0 commit comments