Skip to content

Commit

Permalink
Merge pull request #281 from catalyst/277-fix-trailing-commas
Browse files Browse the repository at this point in the history
style: fix remaining trailing comma phpcs issues
  • Loading branch information
jaypha authored Jul 11, 2022
2 parents bdc5b65 + 709527d commit ff7a595
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion classes/dataflow.php
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ public function get_variables(): array {
'DATAFLOW_RUN_NAME' => $this->engine->run->name ?? null,
],
'dataflow' => $dataflow,
'steps' => $steps
'steps' => $steps,
];
return $variables;
}
Expand Down
2 changes: 1 addition & 1 deletion classes/local/step/connector_s3.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public function execute(): bool {
$config = $this->enginestep->stepdef->config;
$connectionoptions = [
'version' => 'latest',
'region' => $config->region
'region' => $config->region,
];
if ($config->key !== '') {
$connectionoptions['credentials'] = [
Expand Down
11 changes: 6 additions & 5 deletions classes/step.php
Original file line number Diff line number Diff line change
Expand Up @@ -547,11 +547,12 @@ protected function validate_link_count(int $count, string $inputoutput, string $
$steptype = $this->steptype;
[$min, $max] = $steptype->$fn();
if ($count < $min || $count > $max) {
return ["invalid_count_{$inputoutput}{$flowconnector}s_{$this->id}" => get_string(
"stepinvalid{$inputoutput}{$flowconnector}count",
'tool_dataflows',
$count
) . ' ' . visualiser::get_link_expectations($steptype, $inputoutput)
return [
"invalid_count_{$inputoutput}{$flowconnector}s_{$this->id}" => get_string(
"stepinvalid{$inputoutput}{$flowconnector}count",
'tool_dataflows',
$count
) . ' ' . visualiser::get_link_expectations($steptype, $inputoutput),
];
}
return true;
Expand Down
2 changes: 1 addition & 1 deletion edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
// Render the specific dataflow form.
$customdata = [
'persistent' => $persistent ?? null, // An instance, or null.
'userid' => $USER->id // For the hidden userid field.
'userid' => $USER->id, // For the hidden userid field.
];
$form = new dataflow_form($PAGE->url->out(false), $customdata);
if ($form->is_cancelled()) {
Expand Down
2 changes: 1 addition & 1 deletion tests/tool_dataflows_secret_service_test.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ protected static function form_define_fields(): array {
'secret' => ['type' => PARAM_TEXT, 'secret' => true],
'source' => ['type' => PARAM_TEXT],
'target' => ['type' => PARAM_TEXT],
'sourceremote' => ['type' => PARAM_BOOL]
'sourceremote' => ['type' => PARAM_BOOL],
];
}
}
Expand Down

0 comments on commit ff7a595

Please sign in to comment.