mirror of
https://github.com/rectorphp/rector.git
synced 2024-06-02 09:20:52 +00:00
Updated Rector to commit b2ec1f0b413e16760c41707b74c936f7445e13ab
b2ec1f0b41
[Carbon] Skip first class callable on DateTimeMethodCallToCarbonRector (#5893)
This commit is contained in:
parent
22d3d1949d
commit
3f56884569
|
@ -55,6 +55,9 @@ CODE_SAMPLE
|
|||
if (!$this->isName($node->name, 'date')) {
|
||||
return null;
|
||||
}
|
||||
if ($node->isFirstClassCallable()) {
|
||||
return null;
|
||||
}
|
||||
if (\count($node->getArgs()) !== 1) {
|
||||
return null;
|
||||
}
|
||||
|
|
|
@ -71,6 +71,9 @@ CODE_SAMPLE
|
|||
if (!$this->isName($new->class, 'DateTime')) {
|
||||
return null;
|
||||
}
|
||||
if ($new->isFirstClassCallable()) {
|
||||
return null;
|
||||
}
|
||||
if (\count($new->getArgs()) !== 1) {
|
||||
// @todo handle in separate static call
|
||||
return null;
|
||||
|
|
|
@ -54,6 +54,9 @@ CODE_SAMPLE
|
|||
if (!$this->isName($node->class, 'DateTime')) {
|
||||
return null;
|
||||
}
|
||||
if ($node->isFirstClassCallable()) {
|
||||
return null;
|
||||
}
|
||||
// no arg? ::now()
|
||||
$carbonFullyQualified = new FullyQualified('Carbon\\Carbon');
|
||||
if ($node->args === []) {
|
||||
|
|
|
@ -19,12 +19,12 @@ final class VersionResolver
|
|||
* @api
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGE_VERSION = '6ebfa15e733ac340249418057ed3f7615e717ac1';
|
||||
public const PACKAGE_VERSION = 'b2ec1f0b413e16760c41707b74c936f7445e13ab';
|
||||
/**
|
||||
* @api
|
||||
* @var string
|
||||
*/
|
||||
public const RELEASE_DATE = '2024-05-18 20:45:41';
|
||||
public const RELEASE_DATE = '2024-05-18 21:45:11';
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
|
|
Loading…
Reference in New Issue
Block a user