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

Display more logically correct status message when FB user profile details call does not return user data #14

Open
aratidgr8 opened this issue Feb 13, 2024 · 0 comments
Assignees

Comments

@aratidgr8
Copy link
Contributor

aratidgr8 commented Feb 13, 2024

FB details API call

URL: newfold-facebook/v1/facebook/details

In case of failure, we are getting below response:

{
"status": "success",
"details": "token not found!"
}

It seems like this is something that might warrant an error message.
Typically, status might return "error" and then we know that "details" (or maybe "message") would return a note about what went wrong. Look to the wp_send_json_success() and wp_send_json_error() functions for a good pattern.

CC: @wpscholar

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

No branches or pull requests

2 participants