Skip to content
Snippets Groups Projects
Patrick Waller's avatar
opened merge request !11 "Draft: Resolve #3529964 "Support fieldvalue pairs"" at project / contentful
Patrick Waller's avatar
opened merge request !10 "Draft: Resolve #3529953 "Support php 8"" at project / contentful
Sahil Gidwani's avatar
joined project project / contentful
Gaurav Kapoor's avatar
pushed to branch 1.0.x at project / contentful
  • 8e56c53f · Issue #3330527 by AnjaliPrasannan: Add service for accessing common...
Gaurav Kapoor's avatar
accepted merge request !9 "Issue #3330527: Add service for accessing common contentful resources via API" at project / contentful
Gaurav Kapoor's avatar
commented on merge request !9 "Issue #3330527: Add service for accessing common contentful resources via API" at project / contentful

Set it to 'Contentful Client'.

Gaurav Kapoor's avatar
commented on merge request !9 "Issue #3330527: Add service for accessing common contentful resources via API" at project / contentful

Fix coding standards....

Anjali   Prasannan's avatar
opened merge request !9 "Issue #3330527: Add service for accessing common contentful resources via API" at project / contentful
Gaurav Kapoor's avatar
pushed to branch 1.0.x at project / contentful
  • 7e10b959 · Issue #3327261: Add 'Client' service for accessing data from Conten...
Gaurav Kapoor's avatar
accepted merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful
Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Add this value in config YML files as well.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Add a new line at the end of file.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Use dependency injection rather than accessing the service directly. Take hint from this patch https://www.drupal.org/files/issues/2019-10-31/reviv...

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Between line 3 and 4.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Try using dependency injection instead of instantiating Contentful\Delivery\Client using new keyword.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Rename the class and add a new line at the end of the YML file as well.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Add a new line at the end of file.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

This function will just return Client object and not content types.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Don't hardcode credentials, inject the config service and load credentials from configurations.

Gaurav Kapoor's avatar
commented on merge request !8 "Issue #3327261: Add 'Client' service for accessing data from Contentful API" at project / contentful

Fix coding standards as per Drupal specifications.