PluginProbe ʕ •ᴥ•ʔ
Robin Image Optimizer – Unlimited Image Optimization, WebP & AVIF / 2.0.7
Robin Image Optimizer – Unlimited Image Optimization, WebP & AVIF v2.0.7
2.0.7 2.0.6 2.0.5 trunk 1.3.7 1.4.0 1.4.1 1.4.2 1.4.6 1.5.0 1.5.3 1.5.6 1.5.8 1.6.5 1.6.6 1.6.9 1.7.0 1.7.4 1.8.1 1.8.2 1.9.0 2.0.0 2.0.1 2.0.2 2.0.3 2.0.4
robin-image-optimizer / admin / assets / js / meta-migrations.js
robin-image-optimizer / admin / assets / js Last commit date
Chart.min.js 7 months ago bulk-conversion.js 7 months ago bulk-optimization.js 7 months ago calculate-attachments.js 1 year ago index.php 3 years ago meta-migrations.js 3 years ago modals.js 7 months ago notices.js 4 months ago restore-backup.js 7 months ago settings-premium.js 7 months ago single-optimization.js 7 months ago statistic.js 7 months ago sweetalert2.js 3 years ago wrio-license-manager.js 7 months ago
meta-migrations.js
53 lines
1 jQuery(function($) {
2 $('#wbcr-wio-meta-migration-action').on('click', function() {
3
4 var data = {
5 'action': 'wrio_meta_migrations',
6 '_wpnonce': $(this).data('nonce'),
7 };
8
9 $(this).addClass('disabled').text('Please wait...');
10
11 send_request($(this), data);
12 });
13
14 function send_request(button, data) {
15 $.post(window.ajaxurl, data, function(response) {
16
17 console.log(response);
18
19 if( !response || !response.data ) {
20 console.log('An unknown server error has occurred.');
21 console.log(response);
22 return false;
23 }
24
25 if( !response.data.need_more_time ) {
26 if( button.closest('.notice').length ) {
27 button.closest('.notice').remove();
28 }
29 if( button.closest('.alert').length ) {
30 button.closest('.alert').remove();
31 }
32
33 return false;
34 }
35
36 button.text(response.data.message);
37
38 send_request(button, data);
39 }).fail(function(xhr, status, error) {
40 console.log(xhr);
41 console.log(status);
42 console.log(error);
43
44 data.limit = 5;
45 data.error = 1;
46
47 setTimeout(function() {
48 send_request(button, data);
49 }, 2000);
50 });
51 }
52 });
53