Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set from_release parameter in getStories if release is set for client #93

Merged
merged 1 commit into from
Aug 15, 2023

Conversation

hoersamu
Copy link
Contributor

@hoersamu hoersamu commented Aug 9, 2023

Pull request type

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Other (please describe):

How to test this PR

Create a release and copy the ID.
Execute the Code below:

$client = new Client('API key');
$client->setRelease('Release id');
$options = [
  // Slug of a page with changed content in the release
  'by_slugs' => 'slug'
];
$client->getStories($options);

What is the new behavior?

When fetching data from Storyblok using the getStories function the release string set for the client is now respected.

Other information

Fixes #92

@roberto-butti
Copy link
Collaborator

First of all, thank you, @hoersamu, for this PR. Really appreciated. 🥳

@joaokamun and @ademarCardoso , from my point of view, we can merge this PR.
I think it was better to add the unit tests, but I can take the opportunity to check all the other parameters are fine, and eventually, i will open a new PR with all the checks.

@joaokamun joaokamun merged commit d400227 into storyblok:master Aug 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Client->getStories not respecting release
4 participants