Skip to content

Commit

Permalink
API Set extension hook implementation visibility to protected
Browse files Browse the repository at this point in the history
  • Loading branch information
emteknetnz committed May 16, 2024
1 parent 3c8f8b9 commit f6aaa48
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/Forms/CompositeValidator.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
*
* Or by implementing the updateCMSCompositeValidator() method in a DataExtension:
*
* public function updateCMSCompositeValidator(CompositeValidator $compositeValidator): void
* protected function updateCMSCompositeValidator(CompositeValidator $compositeValidator): void
* {
* $compositeValidator->addValidator(RequiredFields::create(['AdditionalContent']));
* }
Expand Down
18 changes: 9 additions & 9 deletions src/ORM/DataExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function validate(ValidationResult $validationResult)
* @param SQLSelect $query Query to augment.
* @param DataQuery $dataQuery Container DataQuery for this SQLSelect
*/
public function augmentSQL(SQLSelect $query, DataQuery $dataQuery = null)
protected function augmentSQL(SQLSelect $query, DataQuery $dataQuery = null)
{
}

Expand All @@ -45,7 +45,7 @@ public function augmentSQL(SQLSelect $query, DataQuery $dataQuery = null)
* When duplicating a table's structure, remember to duplicate the create options
* as well. See {@link Versioned->augmentDatabase} for an example.
*/
public function augmentDatabase()
protected function augmentDatabase()
{
}

Expand All @@ -54,7 +54,7 @@ public function augmentDatabase()
*
* @param array $manipulation Array of operations to augment.
*/
public function augmentWrite(&$manipulation)
protected function augmentWrite(&$manipulation)
{
}

Expand Down Expand Up @@ -206,7 +206,7 @@ public function extraStatics($class = null, $extension = null)
*
* @param FieldList $fields FieldList with a contained TabSet
*/
public function updateCMSFields(FieldList $fields)
protected function updateCMSFields(FieldList $fields)
{
}

Expand All @@ -217,7 +217,7 @@ public function updateCMSFields(FieldList $fields)
*
* @param CompositeValidator $compositeValidator
*/
public function updateCMSCompositeValidator(CompositeValidator $compositeValidator): void
protected function updateCMSCompositeValidator(CompositeValidator $compositeValidator): void
{
}

Expand All @@ -229,7 +229,7 @@ public function updateCMSCompositeValidator(CompositeValidator $compositeValidat
*
* @param FieldList $fields FieldList without TabSet nesting
*/
public function updateFrontEndFields(FieldList $fields)
protected function updateFrontEndFields(FieldList $fields)
{
}

Expand All @@ -239,7 +239,7 @@ public function updateFrontEndFields(FieldList $fields)
*
* @param FieldList $actions FieldList
*/
public function updateCMSActions(FieldList $actions)
protected function updateCMSActions(FieldList $actions)
{
}

Expand All @@ -251,7 +251,7 @@ public function updateCMSActions(FieldList $actions)
*
* @param array $fields Array of field names
*/
public function updateSummaryFields(&$fields)
protected function updateSummaryFields(&$fields)
{
$summary_fields = Config::inst()->get(static::class, 'summary_fields');
if ($summary_fields) {
Expand All @@ -274,7 +274,7 @@ public function updateSummaryFields(&$fields)
*
* @param array $labels Array of field labels
*/
public function updateFieldLabels(&$labels)
protected function updateFieldLabels(&$labels)
{
$field_labels = Config::inst()->get(static::class, 'field_labels');
if ($field_labels) {
Expand Down
2 changes: 1 addition & 1 deletion src/ORM/DataObject.php
Original file line number Diff line number Diff line change
Expand Up @@ -4476,7 +4476,7 @@ protected function mergeRelatedObject($list, $added, $item)
* The framework extend method will return combined values from DataExtension method(s) as an array
* The method on your DataExtension class should return a single scalar value. For example:
*
* public function cacheKeyComponent()
* protected function cacheKeyComponent()
* {
* return (string) $this->owner->MyColumn;
* }
Expand Down

0 comments on commit f6aaa48

Please sign in to comment.