[Plugin: WordPress.com Stats] You are failing to trim user data
-
This message is to the author of the stats plugin.
I have tried to contact you directly but have been unable to determine how.
You are failing to trim user input which is causing your plugin to fail on many installations.
Simply changing:
function stats_get_api_key() {
return stats_get_option(‘api_key’);
}To:
function stats_get_api_key() {
return trim(stats_get_option(‘api_key’));
}fixes the problem. Ideally you would trim it when it’s saved, but I didn’t feel like digging around any more than this.
- The topic ‘[Plugin: WordPress.com Stats] You are failing to trim user data’ is closed to new replies.