After introducing https://www.drupal.org/project/oauth2_client/issues/3040837 there is an issue in ClientTestForm when using an array as scopes definition. In this form the current configuration is displayed but if you use an array in the annotation you receive the following error:

Notice: Array to string conversion in Drupal\oauth2_client\Form\ClientTestForm->Drupal\oauth2_client\Form\{closure}() (line 195 of modules/contrib/oauth2_client/src/Form/ClientTestForm.php).
Drupal\oauth2_client\Form\ClientTestForm->Drupal\oauth2_client\Form\{closure}(Array, 'scopes')

Additionally the README.md file should be updated with the new scope information:
- the syntax for using an array in annotations is '{}' instead of '[]'
- description for scopes and scope_separator should be added

I'll provide a first fix version today.

Comments

sfuchsbe created an issue. See original summary.

sfuchsbe’s picture

Assigned: sfuchsbe » Unassigned
Status: Active » Needs review
StatusFileSize
new1.85 KB
sfuchsbe’s picture

StatusFileSize
new1.86 KB

Rework for 8.x-2.0-beta3

guillaumeduveau’s picture

Status: Needs review » Reviewed & tested by the community

(edit)

guillaumeduveau’s picture

Status: Reviewed & tested by the community » Needs work

Actually, the patch does not apply to latest dev any more. It does fix the PHP notice however, although I didn't test scopes. Also, I'm not sure the comments on scopes are that necessary.

fathershawn’s picture

Status: Needs work » Closed (won't fix)

We are replacing this form in #3187565: Key module integration

fathershawn’s picture

I used the README update in the patch in #3163585: Drupal 9 roadmap and credited @sfuchsbe in that issue