PluginProbe ʕ •ᴥ•ʔ
Backup Migration / 2.1.2
Backup Migration v2.1.2
2.1.6 2.1.5.2 trunk 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.3.9 1.4.0 1.4.1 1.4.2 1.4.3 1.4.4 1.4.5 1.4.6 1.4.6.1 1.4.7 1.4.8 1.4.9 1.4.9.1 2.0.0 2.1.0 2.1.1 2.1.2 2.1.3 2.1.4 2.1.5 2.1.5.1
backup-backup / includes / notices / google-drive-issues.php
backup-backup / includes / notices Last commit date
aws-issues.php 3 months ago backupbliss.php 3 months ago dropbox-issues-notice.php 3 months ago google-drive-issues.php 3 months ago wasabi-issues.php 3 months ago
google-drive-issues.php
56 lines
1 <?php
2
3 // Namespace
4 namespace BMI\Plugin\Dashboard;
5
6 use BMI\Plugin\External\BMI_External_GDrive as GDrive;
7
8 // Exit on direct access
9 if (!defined('ABSPATH')) exit;
10
11 require_once BMI_INCLUDES . '/external/google-drive.php';
12 $GDrive = new GDrive();
13
14 $gdriveIssue = get_transient('bmip_gd_issue');
15
16 if (!$gdriveIssue) return;
17
18 switch ($gdriveIssue) { // REST OF GoogleDrive Notices in backup-backup/include/dashboard/modules/quota-errors.php
19 case 'auth_error_disconnected':
20 $message = sprintf(
21 __('There was an error authenticating your Google Drive account. Please click %shere%s to re-authenticate, or click %shere%s to disable Google Drive as an external storage option.', 'backup-backup'),
22 '<a href="javascript:document.getElementById(\'bmi-error-dismiss\').click();document.getElementById(\'gdrive-connect-btn\').click();">',
23 '</a>',
24 '<a href="javascript:document.getElementById(\'bmi-error-dismiss\').click();document.getElementById(\'bmi-pro-storage-gdrive-toggle\').checked=false;document.querySelector(\'#storage-options .save-btn\').click(); setTimeout(()=>{window.location.reload()}, 500);">',
25 '</a>'
26 );
27 break;
28
29 default:
30 return;
31 }
32
33 if (!isset($message) || get_option('bmip_gdrive_dismiss_issue', false)) return;
34 ?>
35
36
37 <div class="error-noticer" id="gdrive-issues">
38 <div class="error-header">
39 <div class="cf">
40 <div class="left">
41 <?php esc_html_e('We have some error regarding most recent backup upload process.', 'backup-backup'); ?>
42 </div>
43 <div class="right hoverable">
44 <span class="bmi-error-toggle" data-expand="<?php esc_attr_e('Expand', 'backup-backup'); ?>" data-collapse="<?php esc_attr_e('Collapse', 'backup-backup'); ?>">
45 <?php esc_html_e('Expand', 'backup-backup'); ?>
46 </span> |
47 <span id="bmi-error-dismiss">
48 <?php esc_html_e('Dismiss', 'backup-backup'); ?>
49 </span>
50 </div>
51 </div>
52 </div>
53 <div class="error-body">
54 <?php echo wp_kses_post( $message ); ?>
55 </div>
56 </div>