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

Fixed the code section inside Context::initialize method inside the getting_started.md #283

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

SachinBahukhandi
Copy link

@SachinBahukhandi SachinBahukhandi commented Jun 21, 2023

Earlier this change:

Context::initialize(
    apiKey: $_ENV['SHOPIFY_API_KEY'],
    apiSecretKey: $_ENV['SHOPIFY_API_SECRET'],
    scopes: $_ENV['SHOPIFY_APP_SCOPES'],
    hostName: $_ENV['SHOPIFY_APP_HOST_NAME'],
    sessionStorage: new FileSessionStorage('/tmp/php_sessions'),
    apiVersion: '2023-04',
    isEmbeddedApp: true,
    isPrivateApp: false,
);

Would be producing errors.

Thus, replaced it with:

Shopify\Context::initialize(
    'apiKey'=> $_ENV['SHOPIFY_API_KEY'],
    'apiSecretKey'=> $_ENV['SHOPIFY_API_SECRET'],
    'scopes'=> $_ENV['SHOPIFY_APP_SCOPES'],
    'hostName'=> $_ENV['SHOPIFY_APP_HOST_NAME'],
    'sessionStorage'=> new FileSessionStorage('/tmp/php_sessions'),
    'apiVersion'=> '2023-04',
    'isEmbeddedApp'=> true,
    'isPrivateApp'=> false,
);

WHAT is this pull request doing?

Before:
image

After:
image

Type of change

  • Patch: Bug (non-breaking change which fixes an issue)
  • Minor: New feature (non-breaking change which adds functionality)
  • Major: Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist

  • I have added a changelog entry, prefixed by the type of change noted above
  • I have added/updated tests for this change
  • I have updated the documentation for public APIs from the library (if applicable)

@SachinBahukhandi
Copy link
Author

I have signed the CLA!

@shakaran
Copy link
Contributor

@SachinBahukhandi the change is wrong. The documentation is using parameter naming instead an array for this. This PR should be closed

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.

2 participants