diff --git a/fillpdf.install b/fillpdf.install index 11b969de5c8abbc502090f96d3c41fe579e6040d..0f4a91004eae72e2f29e5abf804347b8fe651090 100644 --- a/fillpdf.install +++ b/fillpdf.install @@ -227,7 +227,10 @@ function fillpdf_update_8111() { ->setDescription("Select the type of PDFtk encryption you'd like to use. You should choose 128-bit unless you know otherwise.") ->setCardinality(1) ->setSettings([ - 'allowed_values_function' => [PdftkPdfBackend::class, 'getEncryptionOptions'], + 'allowed_values_function' => [ + PdftkPdfBackend::class, + 'getEncryptionOptions', + ], ]) ->setDisplayOptions('form', [ 'type' => 'options_select', @@ -239,7 +242,10 @@ function fillpdf_update_8111() { ->setCardinality(-1) ->setDescription('Choose the permissions the user should have for the encrypted PDF. If they enter the Owner Password, they will be able to unlock it. <strong>If you do not specify any permissions, then none of these operations will be allowed.</strong>') ->setSettings([ - 'allowed_values_function' => [PdftkPdfBackend::class, 'getUserPermissionList'], + 'allowed_values_function' => [ + PdftkPdfBackend::class, + 'getUserPermissionList', + ], ]) ->setDisplayOptions('form', [ 'type' => 'options_select', diff --git a/src/Entity/FillPdfForm.php b/src/Entity/FillPdfForm.php index 9351e90047c5431e91a4f7b0dbef8e1e641c30bc..b54da353af58c55ad380920472f1fde98286fdce 100644 --- a/src/Entity/FillPdfForm.php +++ b/src/Entity/FillPdfForm.php @@ -159,7 +159,10 @@ class FillPdfForm extends ContentEntityBase implements FillPdfFormInterface { ->setDescription("Select the type of PDFtk encryption you'd like to use. You should choose 128-bit unless you know otherwise.") ->setCardinality(1) ->setSettings([ - 'allowed_values_function' => [PdftkPdfBackend::class, 'getEncryptionOptions'], + 'allowed_values_function' => [ + PdftkPdfBackend::class, + 'getEncryptionOptions', + ], ]) ->setDefaultValue(NULL) ->setDisplayOptions('form', [ @@ -172,7 +175,10 @@ class FillPdfForm extends ContentEntityBase implements FillPdfFormInterface { ->setCardinality(-1) ->setDescription('Choose the permissions the user should have for the encrypted PDF. If they enter the Owner Password, they will be able to unlock it. <strong>If you do not specify any permissions, then none of these operations will be allowed.</strong>') ->setSettings([ - 'allowed_values_function' => [PdftkPdfBackend::class, 'getUserPermissionList'], + 'allowed_values_function' => [ + PdftkPdfBackend::class, + 'getUserPermissionList', + ], ]) ->setDisplayOptions('form', [ 'type' => 'options_buttons', diff --git a/src/Form/FillPdfSettingsForm.php b/src/Form/FillPdfSettingsForm.php index 93dbc81b5b81a4437b609b75aa78344d074759a5..beb44a87084369a9612317885198ff6edbd668ac 100644 --- a/src/Form/FillPdfSettingsForm.php +++ b/src/Form/FillPdfSettingsForm.php @@ -321,8 +321,14 @@ class FillPdfSettingsForm extends ConfigFormBase { // @todo We're working around Core issue #2190333, resp. #2854166. // Remove once one of these landed. See: // https://www.drupal.org/project/drupal/issues/2854166. - $form['shell_locale']['#process'][] = ['Drupal\Core\Render\Element\Select', 'processGroup']; - $form['shell_locale']['#pre_render'][] = ['Drupal\Core\Render\Element\Select', 'preRenderGroup']; + $form['shell_locale']['#process'][] = [ + 'Drupal\Core\Render\Element\Select', + 'processGroup', + ]; + $form['shell_locale']['#pre_render'][] = [ + 'Drupal\Core\Render\Element\Select', + 'preRenderGroup', + ]; } return $form; diff --git a/src/Plugin/PdfBackend/FillPdfServicePdfBackend.php b/src/Plugin/PdfBackend/FillPdfServicePdfBackend.php index 402f85ef70094d8df7220512b73ebac952332232..24d90d22ec1896be504e6c19305e57be70f2b303 100644 --- a/src/Plugin/PdfBackend/FillPdfServicePdfBackend.php +++ b/src/Plugin/PdfBackend/FillPdfServicePdfBackend.php @@ -42,7 +42,7 @@ class FillPdfServicePdfBackend extends PdfBackendBase { if ($result->error == TRUE) { // @todo Throw an exception, log a message etc. return []; - } // after setting error message + } $fields = $result->data;