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

String used as array #8861

Closed
SiR-DanieL opened this issue Aug 17, 2015 · 2 comments
Closed

String used as array #8861

SiR-DanieL opened this issue Aug 17, 2015 · 2 comments
Assignees
Labels
needs: author feedback The issue/PR needs a response from any of the parties involved in the issue.

Comments

@SiR-DanieL
Copy link
Member

In class-wc-ge-ip.php on line 1517 we use $buf as an array but it seems to be a string instead.
This could return errors on some websites, like

Notice: Uninitialized string offset: 0 in public_html/woo/wp-content/plugins/woocommerce/includes/class-wc-geo-ip.php on line 1517

@claudiosanches claudiosanches self-assigned this Aug 17, 2015
@claudiosanches claudiosanches added Needs Dev Feedback needs: author feedback The issue/PR needs a response from any of the parties involved in the issue. and removed Needs Dev Feedback labels Aug 17, 2015
@claudiosanches
Copy link
Contributor

Not really a string.

https://github.com/woothemes/woocommerce/blob/master/includes/class-wc-geo-ip.php#L1511

Maybe this is just the symptom of not having downloaded GeoIPv6.dat file.
You need to check for other error messages because only with that particular line everything is ok.

@SiR-DanieL
Copy link
Member Author

The error is that the file is missing. I'm investigating more to check why it's not downloaded. We can close this issue for now. I'll reopen it if the issue is with WooCommerce. Thanks @claudiosmweb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs: author feedback The issue/PR needs a response from any of the parties involved in the issue.
Projects
None yet
Development

No branches or pull requests

2 participants