Skip to content

typo #955

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

Closed
s-ohnishi opened this issue Apr 21, 2020 · 8 comments · Fixed by sendgrid/php-http-client#141
Closed

typo #955

s-ohnishi opened this issue Apr 21, 2020 · 8 comments · Fixed by sendgrid/php-http-client#141
Labels
difficulty: easy fix is easy in difficulty status: work in progress Twilio or the community is in the process of implementing type: bug bug in the library

Comments

@s-ohnishi
Copy link

Issue Summary

I am using PhpStorm and the warnings are very annoying when using this library.
What is presented as input assistance is different from the one shown in the sample.
I think the cause is that the thing shown in PHPDoc is incorrect.

Steps to Reproduce

  1. This is the first step
  2. This is the second step
  3. Further steps, etc.
    no steps

Code Snippet

// see: https://github.com/sendgrid/sendgrid-php#user-content-general-v3-web-api-usage-with-fluent-interface
    $response = $sg->client->suppression()->bounces()->get();

// vender/sendgrid/php-http-client/lib/Client.php
/**
 *
 * Class Client
 * @package SendGrid
 * @version 3.9.5
...
 * Supressions
 * @method Client suppressions()
 * @method Client global()

maybe
suppressions() --> suppression()

Exception/Log

# paste exception/log here

Technical details:

  • sendgrid-php version: 3.9.5
  • php version: 7.3.14
@childish-sambino
Copy link
Contributor

Not really anything we can/should do here. The name of the endpoint is plural: suppressions. Should be able to add it to your IDE's dictionary.

@childish-sambino childish-sambino added status: waiting for feedback waiting for feedback from the submitter type: question question directed at the library labels Apr 21, 2020
@s-ohnishi
Copy link
Author

plural ?
The following pages I have shown are in singular form.
https://github.com/sendgrid/sendgrid-php#user-content-general-v3-web-api-usage-with-fluent-interface
$response = $sg->client->suppression()->bounces()->get();

https://github.com/sendgrid/sendgrid-php/blob/master/USAGE.md#user-content-get-suppressionbouncesemail
$response = $sg->client->suppression()->bounces()->_($email)->get();

https://sendgrid.com/docs/api-reference/
GET /suppression/bounces
"try it out" tab
https://api.sendgrid.com/v3/suppression/bounces

And I seem to be working fine with "suppression".

@childish-sambino
Copy link
Contributor

@childish-sambino childish-sambino added difficulty: easy fix is easy in difficulty status: work in progress Twilio or the community is in the process of implementing type: bug bug in the library and removed status: waiting for feedback waiting for feedback from the submitter type: question question directed at the library labels Apr 21, 2020
@s-ohnishi
Copy link
Author

I appreciate your understanding of my question.

By the way, the following pages cannot be displayed well in my browser(Firefox 75.0).
The other is fine.
page

https://sendgrid.com/docs/API_Reference/Web_API_v3/bounces.html

@childish-sambino
Copy link
Contributor

Just upgraded to 75.0 on my Windows machine and not seeing any issues. Could you open an issue here with more details about your setup? https://github.com/sendgrid/docs

@s-ohnishi
Copy link
Author

I have tried. Currently it seems to be displayed without problems.
I don't know what happened, but the tab displaying the faulty page was still there, so I saved it and tried a diff.

There seems to be a difference between the two files SendGrid.htm and SendGrid_files\a.
However, I was able to view the saved file locally without any problems.

I don't know if it will be helpful, but I will attach some files.
The file a is not clear in the diff, so rename it OK_a.txt, NG_a.txt.

diff.txt
NG_a.txt
OK_a.txt

@childish-sambino
Copy link
Contributor

Best to add the details to a new issue here: https://github.com/sendgrid/docs

@s-ohnishi
Copy link
Author

sorry.
I don't reproduce the situation right now, just provide information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty: easy fix is easy in difficulty status: work in progress Twilio or the community is in the process of implementing type: bug bug in the library
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants