Skip to content

Conversation

@atensoftware
Copy link
Contributor

On certain BigCommerce stores, getHeader fails because the X-BC-ApiLimit-Remaining header is all lower-case in the HTTP response. This causes getRequestsRemaining to always return 0 and puts the code into an infinite wait for more requests. Instead, change getHeader to do a case-insensitive search for the header if the exact case is not found. Please merge this into the trunk. The code keeps breaking every time I update the library.

I had created a previous pull request to fix this, but I don't think it got fixed:
#196

On certain BigCommerce stores, getHeader fails because the X-BC-ApiLimit-Remaining header is all lower-case in the HTTP response.  This causes getRequestsRemaining to always return 0 and puts the code into an infinite wait for more requests.  Instead, change getHeader to do a case-insensitive search for the header if the exact case is not found.  Please merge this into the trunk.
@lord2800
Copy link
Contributor

Hey, thanks for fixing this (again)! Can you take a look at the Travis failures?

@atensoftware
Copy link
Contributor Author

Travis was just complaining about spacing. I fixed it.

@lord2800 lord2800 merged commit adcafe4 into bigcommerce:master Jan 10, 2019
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