Skip to content

Commit

Permalink
Wordpress: HTML decode selectors when upgrading from pre 2.5
Browse files Browse the repository at this point in the history
  • Loading branch information
samcleaver committed Dec 17, 2012
1 parent a477cd0 commit 9ec1b55
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions wordpress-plugin/infinite-scroll.php
Expand Up @@ -224,6 +224,13 @@ function upgrade( $from , $to ) {

}

//pre 2.5 we html encoded selectors, we don't do this anymore
foreach ( array( 'contentSelector', 'itemSelector', 'navSelector', 'nextSelector' ) as $field ) {
if ( isset( $new[$field] ) ) {
$new[$field] = html_entity_decode($new[$field]);
}
}

//regardless of which upgrade we did, move loading string to array
$new['loading'] = array( );

Expand Down

0 comments on commit 9ec1b55

Please sign in to comment.