Notice: Undefined offset: 2 in inc/wpseo-non-ajax-functions.php on line 506 #492

Closed
swinggraphics opened this Issue Dec 24, 2013 · 4 comments

2 participants

@swinggraphics

Nice and quick: add @ symbol before $args[2] on line 506

@jrfnl

Not a good fix as the error is an indication of an underlying problem, i.e. the post ID not being passed and it therefore not being a valid request for authorization.

Better would be to add an isset( $args[2] ) at the start of the if() clause as if it's not set the return value should not be changed.

@swinggraphics

Absolutely. I hadn't thought it through.

@swinggraphics swinggraphics reopened this Dec 24, 2013
@jrfnl jrfnl added a commit to jrfnl/wordpress-seo that referenced this issue Dec 26, 2013
@jrfnl jrfnl Fix issue #492 82083eb
@jrfnl

Closing in favour of pull request #499 which solves this.

@jrfnl jrfnl closed this Dec 26, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment