← All changes
|
vendor/codeinwp/themeisle-sdk/src/Modules/Rollback.php
+7
-1
3.1.3
→
3.4.9
View file →
| @@ -166,9 +166,9 @@ | ||
| 166 | 166 | if ( $this->product->requires_license() && strlen( $license ) < 10 ) { |
| 167 | 167 | return ''; |
| 168 | 168 | } |
| 169 | 169 | |
| 170 | - return sprintf( '%s?edd_action=get_versions&name=%s&url=%s&license=%s', $this->product->get_store_url(), urlencode( $this->product->get_name() ), urlencode( get_site_url() ), $license ); | |
| 170 | + return sprintf( '%slicense/versions/%s/%s/%s/%s', Product::API_URL, rawurlencode( $this->product->get_name() ), $license, urlencode( get_site_url() ), $this->product->get_version() ); | |
| 171 | 171 | } |
| 172 | 172 | |
| 173 | 173 | /** |
| 174 | 174 | * Show the rollback links in the plugin page. |
| @@ -227,8 +227,11 @@ | ||
| 227 | 227 | set_site_transient( 'update_plugins', $plugin_transient ); |
| 228 | 228 | |
| 229 | 229 | $transient = get_transient( $this->product->get_key() . '_warning_rollback' ); |
| 230 | 230 | |
| 231 | + // Style fix for the api link that gets outside the content. | |
| 232 | + echo '<style>body#error-page{word-break:break-word;}</style>'; | |
| 233 | + | |
| 231 | 234 | if ( false === $transient ) { |
| 232 | 235 | set_transient( $this->product->get_key() . '_warning_rollback', 'in progress', 30 ); |
| 233 | 236 | require_once( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); |
| 234 | 237 | $title = sprintf( apply_filters( $this->product->get_key() . '_rollback_message', 'Rolling back %s to v%s' ), $this->product->get_name(), $version ); |
| @@ -266,8 +269,11 @@ | ||
| 266 | 269 | $transient->response[ $folder . '/style.css' ] = $temp_array; |
| 267 | 270 | set_site_transient( 'update_themes', $transient ); |
| 268 | 271 | |
| 269 | 272 | $transient = get_transient( $this->product->get_key() . '_warning_rollback' ); |
| 273 | + | |
| 274 | + // Style fix for the api link that gets outside the content. | |
| 275 | + echo '<style>body#error-page{word-break:break-word;}</style>'; | |
| 270 | 276 | |
| 271 | 277 | if ( false === $transient ) { |
| 272 | 278 | set_transient( $this->product->get_key() . '_warning_rollback', 'in progress', 30 ); |
| 273 | 279 | require_once( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); |