Skip to content

Commit

Permalink
Apply phpcs fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
DieterHolvoet committed Nov 24, 2021
1 parent 16d9adb commit aaced26
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/Drupal/Commands/core/FieldCreateCommands.php
Expand Up @@ -717,7 +717,7 @@ public static function validateRequired(?string $value): string
{
// FALSE is not considered as empty value because question helper use
// it as negative answer on confirmation questions.
if ($value === NULL || $value === '') {
if ($value === null || $value === '') {
throw new \UnexpectedValueException('This value is required.');
}

Expand Down
6 changes: 2 additions & 4 deletions src/Drupal/Commands/core/LinkHooks.php
Expand Up @@ -46,8 +46,7 @@ public function hookOption(Command $command, AnnotationData $annotationData): vo
/** @hook on-event field-create-set-options */
public function hookSetOptions(InputInterface $input): void
{
if (
!$this->isInstalled()
if (!$this->isInstalled()
|| $input->getOption('field-type') !== 'link'
) {
return;
Expand All @@ -67,8 +66,7 @@ public function hookSetOptions(InputInterface $input): void
/** @hook on-event field-create-field-config */
public function hookFieldConfig(array $values, InputInterface $input): array
{
if (
!$this->isInstalled()
if (!$this->isInstalled()
|| $values['field_type'] !== 'link'
) {
return $values;
Expand Down

0 comments on commit aaced26

Please sign in to comment.