Skip to content

Commit

Permalink
Fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxime Rainville committed Aug 3, 2023
1 parent f6082dc commit a41345b
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 8 deletions.
2 changes: 1 addition & 1 deletion src/Form/AllowedClassesTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ public function setRecursivelyAddChildClass(bool $recursivelyAddChildClass): sel
return $this;
}

protected abstract function guessBaseClass(): ?string;
abstract protected function guessBaseClass(): ?string;

public function getAllowedDataObjectClasses(): array
{
Expand Down
1 change: 0 additions & 1 deletion src/Form/AnyField.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,4 @@ public function InitialHTML()
{
return $this->renderWith(static::class . '_InitialHTML');
}

}
1 change: 0 additions & 1 deletion src/Form/JsonField.php
Original file line number Diff line number Diff line change
Expand Up @@ -146,5 +146,4 @@ public function InputValue(): string
* Should throw an exception if the class name is not valid.
*/
abstract protected function validClassName(string $className): void;

}
2 changes: 0 additions & 2 deletions src/Form/ManyAnyField.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ public function saveInto(DataObjectInterface $record)

/** @var HasMany|DataObject[] $links */
if ($datalist = $record->$fieldname()) {

// Loop through all the existing data objects and update/delete them as needed.
foreach ($datalist as $do) {
// As we process a dataobject we remove it from the value array
Expand Down Expand Up @@ -180,7 +179,6 @@ private function guessBaseClass(): ?string

$class = DataObject::getSchema()->hasManyComponent(get_class($record), $fieldname);
return $class;

}

public function InputValue(): string
Expand Down
1 change: 0 additions & 1 deletion tests/behat/src/FixtureContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,5 @@ protected function getModal(): ?NodeElement
{
$page = $this->getMainContext()->getSession()->getPage();
return $page->find('css', '[role=dialog]');

}
}
1 change: 0 additions & 1 deletion tests/php/Form/AllowedClassesTraitTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,5 +97,4 @@ public function testAllowedDataObjectClasses(bool $recursive, array $excluded)
'getAllowedDataObjectClasses() relays the correct parameter to AnyService::getAllowedDataObjectClasses()'
);
}

}
1 change: 0 additions & 1 deletion tests/php/Form/ManyAnyFieldTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
use SilverStripe\LinkField\Models\EmailLink;
use SilverStripe\AnyField\Services\AnyService;


class ManyAnyFieldTest extends AllowedClassesTraitTestCase
{

Expand Down

0 comments on commit a41345b

Please sign in to comment.