iThemes Sync - Version 2.0.4

Version Description

  • Ignored Language Pack Updates when updating Core/Plugins/Themes, for now
Download this release

Release Info

Developer layotte
Plugin Icon 128x128 iThemes Sync
Version 2.0.4
Comparing to
See all releases

Code changes from version 2.0.3 to 2.0.4

admin.php CHANGED
@@ -115,7 +115,7 @@ class Ithemes_Sync_Admin {
115
 
116
  ?>
117
  <div class="updated" id="ithemes-sync-notice">
118
- <?php printf( __( 'iThemes Sync is active. <a class="ithemes-sync-notice-button" href="%s">Manage Sync</a> <a class="ithemes-sync-notice-dismiss" href="#">×</a>', 'it-l10n-ithemes-sync' ), $url ); ?>
119
  </div>
120
  <?php
121
 
@@ -129,7 +129,7 @@ class Ithemes_Sync_Admin {
129
 
130
  ?>
131
  <div class="updated" id="ithemes-sync-notice">
132
- <?php printf( __( 'iThemes Sync is almost ready. <a class="ithemes-sync-notice-button" href="%s">Set Up Sync</a> <a class="ithemes-sync-notice-hide" href="#">×</a>', 'it-l10n-ithemes-sync' ), $url ); ?>
133
  </div>
134
  <?php
135
 
@@ -144,7 +144,7 @@ class Ithemes_Sync_Admin {
144
 
145
  ?>
146
  <div class="updated">
147
- <p><?php printf( __( 'iThemes Sync will show for your user for the next %1$s. Click <a href="%2$s">here</a> to hide iThemes Sync again.', 'it-l10n-ithemes-sync' ), $time_diff, $url ); ?></p>
148
  </div>
149
  <?php
150
 
@@ -154,7 +154,7 @@ class Ithemes_Sync_Admin {
154
 
155
  ?>
156
  <div class="updated">
157
- <p><?php _e( 'iThemes Sync is now hidden from your user again.', 'it-l10n-ithemes-sync' ); ?></p>
158
  </div>
159
  <?php
160
 
@@ -165,13 +165,13 @@ class Ithemes_Sync_Admin {
165
  }
166
 
167
  public function add_admin_pages() {
168
- $this->page_ref = add_options_page( __( 'iThemes Sync', 'it-l10n-ithemes-sync' ), __( 'iThemes Sync', 'it-l10n-ithemes-sync' ), 'manage_options', $this->page_name, array( $this, 'settings_index' ) );
169
 
170
  add_action( "load-{$this->page_ref}", array( $this, 'load_settings_page' ) );
171
  }
172
 
173
  public function add_network_admin_pages() {
174
- $this->page_ref = add_submenu_page( 'settings.php', __( 'iThemes Sync', 'it-l10n-ithemes-sync' ), __( 'iThemes Sync', 'it-l10n-ithemes-sync' ), 'manage_options', $this->page_name, array( $this, 'settings_index' ) );
175
 
176
  add_action( "load-{$this->page_ref}", array( $this, 'load_settings_page' ) );
177
  }
@@ -199,7 +199,7 @@ class Ithemes_Sync_Admin {
199
  return;
200
 
201
  $url = admin_url( 'options-general.php' ) . "?page={$this->page_name}";
202
- $this->registration_link = sprintf( '<a href="%1$s" title="%2$s">%3$s</a>', $url, __( 'Manage iThemes product licenses to receive automatic upgrade support', 'it-l10n-ithemes-sync' ), __( 'License', 'it-l10n-ithemes-sync' ) );
203
  }
204
 
205
  public function filter_plugin_action_links( $actions, $plugin_file, $plugin_data, $context ) {
115
 
116
  ?>
117
  <div class="updated" id="ithemes-sync-notice">
118
+ <?php printf( __( 'iThemes Sync is active. <a class="ithemes-sync-notice-button" href="%s">Manage Sync</a> <a class="ithemes-sync-notice-dismiss" href="#">×</a>', 'LION' ), $url ); ?>
119
  </div>
120
  <?php
121
 
129
 
130
  ?>
131
  <div class="updated" id="ithemes-sync-notice">
132
+ <?php printf( __( 'iThemes Sync is almost ready. <a class="ithemes-sync-notice-button" href="%s">Set Up Sync</a> <a class="ithemes-sync-notice-hide" href="#">×</a>', 'LION' ), $url ); ?>
133
  </div>
134
  <?php
135
 
144
 
145
  ?>
146
  <div class="updated">
147
+ <p><?php printf( __( 'iThemes Sync will show for your user for the next %1$s. Click <a href="%2$s">here</a> to hide iThemes Sync again.', 'LION' ), $time_diff, $url ); ?></p>
148
  </div>
149
  <?php
150
 
154
 
155
  ?>
156
  <div class="updated">
157
+ <p><?php _e( 'iThemes Sync is now hidden from your user again.', 'LION' ); ?></p>
158
  </div>
159
  <?php
160
 
165
  }
166
 
167
  public function add_admin_pages() {
168
+ $this->page_ref = add_options_page( __( 'iThemes Sync', 'LION' ), __( 'iThemes Sync', 'LION' ), 'manage_options', $this->page_name, array( $this, 'settings_index' ) );
169
 
170
  add_action( "load-{$this->page_ref}", array( $this, 'load_settings_page' ) );
171
  }
172
 
173
  public function add_network_admin_pages() {
174
+ $this->page_ref = add_submenu_page( 'settings.php', __( 'iThemes Sync', 'LION' ), __( 'iThemes Sync', 'LION' ), 'manage_options', $this->page_name, array( $this, 'settings_index' ) );
175
 
176
  add_action( "load-{$this->page_ref}", array( $this, 'load_settings_page' ) );
177
  }
199
  return;
200
 
201
  $url = admin_url( 'options-general.php' ) . "?page={$this->page_name}";
202
+ $this->registration_link = sprintf( '<a href="%1$s" title="%2$s">%3$s</a>', $url, __( 'Manage iThemes product licenses to receive automatic upgrade support', 'LION' ), __( 'License', 'LION' ) );
203
  }
204
 
205
  public function filter_plugin_action_links( $actions, $plugin_file, $plugin_data, $context ) {
duplicator.php CHANGED
@@ -28,7 +28,7 @@ function ithemes_sync_duplicate_post_addon_get_duplicating_url( $post ) {
28
  */
29
  function ithemes_sync_duplicate_post_addon_add_duplicate_post_function( $actions, $post ) {
30
  $url = ithemes_sync_duplicate_post_addon_get_duplicating_url( $post );
31
- $actions['ithemes_sync_duplicate'] = '<a class="sync_duplicate_post" id="sync-post-' . $post->ID . '" title="' . __( 'Duplicate Post', 'it-l10n-ithemes-sync' ) . '" href="' . $url . '">Duplicate</a>';
32
 
33
  return $actions;
34
  }
28
  */
29
  function ithemes_sync_duplicate_post_addon_add_duplicate_post_function( $actions, $post ) {
30
  $url = ithemes_sync_duplicate_post_addon_get_duplicating_url( $post );
31
+ $actions['ithemes_sync_duplicate'] = '<a class="sync_duplicate_post" id="sync-post-' . $post->ID . '" title="' . __( 'Duplicate Post', 'LION' ) . '" href="' . $url . '">Duplicate</a>';
32
 
33
  return $actions;
34
  }
history.txt CHANGED
@@ -186,3 +186,5 @@
186
  Bug Fix: Adding code to get-authentication-token verb to set the scheme to https by default if it should be
187
  2.0.3 - 2017-09-26 - Glenn Ansley
188
  Improvement: Refactored verbs to improve add-site function from Sync Dashboard.
 
 
186
  Bug Fix: Adding code to get-authentication-token verb to set the scheme to https by default if it should be
187
  2.0.3 - 2017-09-26 - Glenn Ansley
188
  Improvement: Refactored verbs to improve add-site function from Sync Dashboard.
189
+ 2.0.4 - 2017-12-21 - Lew Ayotte
190
+ Bug Fix: Ignored Language Pack Updates when updating Core/Plugins/Themes, for now
images/sync-icon.png ADDED
Binary file
init.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: iThemes Sync
4
  Plugin URI: http://ithemes.com/sync
5
  Description: Manage updates to your WordPress sites easily in one place.
6
  Author: iThemes
7
- Version: 2.0.3
8
  Author URI: http://ithemes.com/
9
  Domain Path: /lang/
10
  iThemes Package: ithemes-sync
@@ -16,7 +16,7 @@ if ( ! empty( $GLOBALS['ithemes_sync_path'] ) ) {
16
 
17
  if ( $active_plugin_path != $this_plugin_path ) {
18
  $function = 'echo \'<div class="error"><p>';
19
- $function .= sprintf( __( 'Only one iThemes Sync plugin can be active at a time. The plugin at <code>%1$s</code> is running while the plugin at <code>%2$s</code> was skipped in order to prevent errors. Please deactivate the plugin that you do not wish to use.', 'it-l10n-ithemes-sync' ), $active_plugin_path, $this_plugin_path );
20
  $function .= '</p></div>\';';
21
 
22
  $function_ref = create_function( '', $function );
4
  Plugin URI: http://ithemes.com/sync
5
  Description: Manage updates to your WordPress sites easily in one place.
6
  Author: iThemes
7
+ Version: 2.0.4
8
  Author URI: http://ithemes.com/
9
  Domain Path: /lang/
10
  iThemes Package: ithemes-sync
16
 
17
  if ( $active_plugin_path != $this_plugin_path ) {
18
  $function = 'echo \'<div class="error"><p>';
19
+ $function .= sprintf( __( 'Only one iThemes Sync plugin can be active at a time. The plugin at <code>%1$s</code> is running while the plugin at <code>%2$s</code> was skipped in order to prevent errors. Please deactivate the plugin that you do not wish to use.', 'LION' ), $active_plugin_path, $this_plugin_path );
20
  $function .= '</p></div>\';';
21
 
22
  $function_ref = create_function( '', $function );
load-translations.php CHANGED
@@ -15,7 +15,7 @@ Version History
15
 
16
 
17
  $ithemes_sync_plugin_dir = basename( $GLOBALS['ithemes_sync_path'] );
18
- $ithemes_sync_locale = apply_filters( 'plugin_locale', get_locale(), 'it-l10n-ithemes-sync' );
19
 
20
- load_textdomain( 'it-l10n-ithemes-sync', WP_LANG_DIR . "/plugins/ithemes-sync/it-l10n-ithemes-sync-$ithemes_sync_locale.mo" );
21
- load_plugin_textdomain( 'it-l10n-ithemes-sync', false, "$ithemes_sync_plugin_dir/lang/" );
15
 
16
 
17
  $ithemes_sync_plugin_dir = basename( $GLOBALS['ithemes_sync_path'] );
18
+ $ithemes_sync_locale = apply_filters( 'plugin_locale', get_locale(), 'LION' );
19
 
20
+ load_textdomain( 'LION', WP_LANG_DIR . "/plugins/ithemes-sync/it-l10n-ithemes-sync-$ithemes_sync_locale.mo" );
21
+ load_plugin_textdomain( 'LION', false, "$ithemes_sync_plugin_dir/lang/" );
notice-handler.php CHANGED
@@ -86,7 +86,7 @@ class Ithemes_Sync_Notice_Handler {
86
  return true;
87
  }
88
 
89
- return new WP_Error( 'unknown-response', __( 'The Sync server returned an unknown response.', 'it-l10n-ithemes-sync' ) );
90
  }
91
 
92
  public function get_urgent_notices() {
86
  return true;
87
  }
88
 
89
+ return new WP_Error( 'unknown-response', __( 'The Sync server returned an unknown response.', 'LION' ) );
90
  }
91
 
92
  public function get_urgent_notices() {
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: ithemes, layotte, blepoxp
3
  Tags: manage multiple Sites, backup, security, migrate, SEO, manage updates, administration, update manager, reports, sync, google analytics, optimize, uptime, ithemes, customize dashboard, client sites, maintenance, management, google webmaster tools, reporting
4
  Requires at least: 4.5
5
- Tested up to: 4.8
6
- Stable tag: 2.0.3
7
  License: GPLv3 or later
8
  License URI: http://www.gnu.org/licenses/quick-guide-gplv3.html
9
 
@@ -86,6 +86,9 @@ Make steady, reliable income for WordPress maintenance with iThemes Sync Pro’s
86
 
87
  == Changelog ==
88
 
 
 
 
89
  = 2.0.3 =
90
  * Refactored verbs to improve add-site function from Sync Dashboard
91
 
2
  Contributors: ithemes, layotte, blepoxp
3
  Tags: manage multiple Sites, backup, security, migrate, SEO, manage updates, administration, update manager, reports, sync, google analytics, optimize, uptime, ithemes, customize dashboard, client sites, maintenance, management, google webmaster tools, reporting
4
  Requires at least: 4.5
5
+ Tested up to: 4.9
6
+ Stable tag: 2.0.4
7
  License: GPLv3 or later
8
  License URI: http://www.gnu.org/licenses/quick-guide-gplv3.html
9
 
86
 
87
  == Changelog ==
88
 
89
+ = 2.0.4 =
90
+ * Ignored Language Pack Updates when updating Core/Plugins/Themes, for now
91
+
92
  = 2.0.3 =
93
  * Refactored verbs to improve add-site function from Sync Dashboard
94
 
server.php CHANGED
@@ -185,7 +185,7 @@ class Ithemes_Sync_Server {
185
  $body = json_decode( $response['body'], true );
186
 
187
  if ( ! is_array( $body ) ) {
188
- return new WP_Error( 'ithemes-sync-server-unknown-response', __( 'An unrecognized server response format was received from the iThemes Sync server.', 'it-l10n-ithemes-sync' ) );
189
  }
190
 
191
  if ( ! empty( $body['error'] ) ) {
185
  $body = json_decode( $response['body'], true );
186
 
187
  if ( ! is_array( $body ) ) {
188
+ return new WP_Error( 'ithemes-sync-server-unknown-response', __( 'An unrecognized server response format was received from the iThemes Sync server.', 'LION' ) );
189
  }
190
 
191
  if ( ! empty( $body['error'] ) ) {
settings-page.php CHANGED
@@ -51,7 +51,7 @@ class Ithemes_Sync_Settings_Page {
51
  $var = 'ithemes-updater-settings-page-script';
52
 
53
  $translations = array(
54
- 'confirm_dialog_text' => __( 'Are you sure that you wish to unsync this user?', 'it-l10n-ithemes-sync' ),
55
  );
56
 
57
  wp_enqueue_script( $var, "{$this->path_url}/js/settings-page.js", array( 'jquery' ) );
@@ -88,14 +88,14 @@ class Ithemes_Sync_Settings_Page {
88
  $result = Ithemes_Sync_Server::authenticate( $data['username'], $data['password'] );
89
 
90
  if ( is_wp_error( $result ) ) {
91
- $heading = __( 'The user could not be synced.', 'it-l10n-ithemes-sync' );
92
 
93
  $code = $result->get_error_code();
94
 
95
  if ( 'http_request_failed' == $code )
96
- $message = sprintf( __( '<p>The iThemes Sync server was unable to be contacted. WordPress returned the following error when trying to contact the server:</p><p>%1$s</p><p>If you continue to experience problems, please contact <a target="_blank" href="%2$s">iThemes support</a>.</p>', 'it-l10n-ithemes-sync' ), $result->get_error_message(), 'http://ithemes.com/support/' );
97
  else if ( 'ithemes-sync-server-failed-request' == $code )
98
- $message = sprintf( __( '<p>The iThemes Sync server was unable to process the request at this time. Please try again in a few minutes.</p><p>If you continue to experience problems, please contact <a target="_blank" href="%s">iThemes support</a>.</p>', 'it-l10n-ithemes-sync' ), 'http://ithemes.com/support/' );
99
  else
100
  $message = $result->get_error_message();
101
 
@@ -105,8 +105,8 @@ class Ithemes_Sync_Settings_Page {
105
  }
106
 
107
  if ( empty( $result['key'] ) ) {
108
- $heading = __( 'The user could not be synced.', 'it-l10n-ithemes-sync' );
109
- $message = __( 'The sync request failed due to a server communication error. The server sent a response that did not include a authentication key.', 'it-l10n-ithemes-sync' );
110
 
111
  $this->add_error_message( $heading, $message );
112
 
@@ -114,8 +114,8 @@ class Ithemes_Sync_Settings_Page {
114
  }
115
 
116
  if ( empty( $result['user_id'] ) ) {
117
- $heading = __( 'The user could not be synced.', 'it-l10n-ithemes-sync' );
118
- $message = __( 'The sync request failed due to a server communication error. The server sent a response that did not include a user ID.', 'it-l10n-ithemes-sync' );
119
 
120
  $this->add_error_message( $heading, $message );
121
 
@@ -126,7 +126,7 @@ class Ithemes_Sync_Settings_Page {
126
  $add_result = $GLOBALS['ithemes-sync-settings']->add_authentication( $result['user_id'], $data['username'], $result['key'] );
127
 
128
  if ( is_wp_error( $add_result ) ) {
129
- $heading = __( 'The user could not be synced.', 'it-l10n-ithemes-sync' );
130
  $message = $add_result->get_error_message();
131
 
132
  $this->add_error_message( $heading, $message );
@@ -135,13 +135,13 @@ class Ithemes_Sync_Settings_Page {
135
  }
136
 
137
 
138
- $heading = __( 'Woohoo! Your site has been synced.', 'it-l10n-ithemes-sync' );
139
  $messages = array();
140
 
141
  if ( 0 == $result['quota']['available'] )
142
- $messages[] = sprintf( __( 'Your user has now used all of the sites available to be added to Sync. More information can be found on the <a href="%s" target="_blank">iThemes membership panel</a>.', 'it-l10n-ithemes-sync' ), $this->sync_dashboard_url );
143
  else
144
- $messages[] = sprintf( _n( 'Your user can Sync 1 additional site.', 'Your user can sync %d additional sites.', $result['quota']['available'], 'it-l10n-ithemes-sync' ), $result['quota']['available'] );
145
 
146
  $this->add_success_message( $heading, $messages );
147
  }
@@ -157,7 +157,7 @@ class Ithemes_Sync_Settings_Page {
157
  $result = Ithemes_Sync_Server::deauthenticate( $data['user'], $user_details['username'], $user_details['key'] );
158
 
159
  if ( is_wp_error( $result ) && ( 'authentication' != $result->get_error_code() ) ) {
160
- $heading = __( 'The user could not be unsynced.', 'it-l10n-ithemes-sync' );
161
  $message = $result->get_error_message();
162
 
163
  $this->add_error_message( $heading, $message );
@@ -169,7 +169,7 @@ class Ithemes_Sync_Settings_Page {
169
  $result = $GLOBALS['ithemes-sync-settings']->remove_authentication( $data['user'], $user_details['username'] );
170
 
171
  if ( is_wp_error( $result ) ) {
172
- $heading = __( 'The user could not be unsynced.', 'it-l10n-ithemes-sync' );
173
  $message = $result->get_error_message();
174
 
175
  $this->add_error_message( $heading, $message );
@@ -178,7 +178,7 @@ class Ithemes_Sync_Settings_Page {
178
  }
179
 
180
 
181
- $heading = __( 'The user was successfully unsynced.', 'it-l10n-ithemes-sync' );
182
 
183
  $this->add_success_message( $heading );
184
  }
@@ -236,7 +236,7 @@ class Ithemes_Sync_Settings_Page {
236
 
237
  $GLOBALS['ithemes-sync-settings']->update_options( $settings );
238
 
239
- $this->messages[] = __( 'Settings saved', 'it-l10n-ithemes-sync' );
240
  }
241
 
242
  public function show_settings() {
@@ -263,9 +263,9 @@ class Ithemes_Sync_Settings_Page {
263
  ?>
264
  <div class="ithemes-sync-wrapper wrap">
265
  <?php if ( empty( $this->options['authentications'] ) ) : ?>
266
- <h2><?php _e( 'Sync This Site', 'it-l10n-ithemes-sync' ); ?></h2>
267
  <?php else : ?>
268
- <h2><?php _e( 'iThemes Sync', 'it-l10n-ithemes-sync' ); ?></h2>
269
  <?php endif; ?>
270
 
271
 
@@ -273,16 +273,16 @@ class Ithemes_Sync_Settings_Page {
273
 
274
 
275
  <?php if ( ! empty( $this->options['authentications'] ) ) : ?>
276
- <a class="ithemes-sync-button" href="<?php echo $this->sync_dashboard_url; ?>" target="_blank"><?php _e( 'Go Manage Your Synced Sites', 'it-l10n-ithemes-sync' ); ?></a>
277
 
278
  <div class="ithemes-sync-section ithemes-sync-manage-users">
279
- <h3><?php _e( 'Manage Synced Users', 'it-l10n-ithemes-sync' ); ?></h3>
280
 
281
- <p><?php _e( 'Sync allows you to sync your site with multiple users.<br>View the list of synced users below, unsync users if needed, or add additional users below.', 'it-l10n-ithemes-sync' ); ?></p>
282
 
283
  <?php if ( ! empty( $valid_users ) ) : ?>
284
  <div class="ithemes-sync-users ithemes-sync-valid-users">
285
- <h4><?php _e( 'Synced Users', 'it-l10n-ithemes-sync' ); ?></h4>
286
 
287
  <ul>
288
  <?php foreach ( $valid_users as $user_id ) : ?>
@@ -297,9 +297,9 @@ class Ithemes_Sync_Settings_Page {
297
 
298
  <?php if ( ! empty( $invalid_users ) ) : ?>
299
  <div class="ithemes-sync-users ithemes-sync-invalid-users">
300
- <h4><?php _e( 'Invalid Users', 'it-l10n-ithemes-sync' ); ?></h4>
301
 
302
- <p><?php _e( 'The following users were not recognized by the server. Unsync them and resync them again to fix this error.', 'it-l10n-ithemes-sync' ); ?></p>
303
 
304
  <ul>
305
  <?php foreach ( $invalid_users as $user_id ) : ?>
@@ -317,20 +317,20 @@ class Ithemes_Sync_Settings_Page {
317
 
318
  <div class="ithemes-sync-section ithemes-sync-authorize">
319
  <?php if ( empty( $this->options['authentications'] ) ) : ?>
320
- <p><?php _e( 'Enter your iThemes username & password to sync this site.', 'it-l10n-ithemes-sync' ); ?></p>
321
  <?php else : ?>
322
- <h3><?php _e( 'Add Users', 'it-l10n-ithemes-sync' ); ?></h3>
323
- <p><?php _e( 'Add additional users if more than one person will be managing updates for this site.<br>To sync an additional user, enter their iThemes username and password below.', 'it-l10n-ithemes-sync' ); ?></p>
324
  <?php endif; ?>
325
 
326
  <form id="ithemes-sync-authenticate" enctype="multipart/form-data" method="post" action="<?php echo $this->self_url; ?>">
327
- <label for="username"><?php _e( 'Username', 'it-l10n-ithemes-sync' ); ?></label><br>
328
  <input type="text" id="username" name="username" value="<?php if ( $this->had_error ) echo esc_attr( $post_data['username'] ); ?>">
329
 
330
- <label for="password"><?php _e( 'Password', 'it-l10n-ithemes-sync' ); ?></label><br>
331
  <input type="password" id="password" name="password" value="<?php if ( $this->had_error ) echo esc_attr( $post_data['password'] ); ?>">
332
 
333
- <input type="submit" id="submit" value="<?php _e( 'Sync', 'it-l10n-ithemes-sync' ); ?>">
334
  <input type="hidden" name="action" value="authenticate">
335
 
336
  <?php wp_nonce_field( 'authenticate-user' ); ?>
51
  $var = 'ithemes-updater-settings-page-script';
52
 
53
  $translations = array(
54
+ 'confirm_dialog_text' => __( 'Are you sure that you wish to unsync this user?', 'LION' ),
55
  );
56
 
57
  wp_enqueue_script( $var, "{$this->path_url}/js/settings-page.js", array( 'jquery' ) );
88
  $result = Ithemes_Sync_Server::authenticate( $data['username'], $data['password'] );
89
 
90
  if ( is_wp_error( $result ) ) {
91
+ $heading = __( 'The user could not be synced.', 'LION' );
92
 
93
  $code = $result->get_error_code();
94
 
95
  if ( 'http_request_failed' == $code )
96
+ $message = sprintf( __( '<p>The iThemes Sync server was unable to be contacted. WordPress returned the following error when trying to contact the server:</p><p>%1$s</p><p>If you continue to experience problems, please contact <a target="_blank" href="%2$s">iThemes support</a>.</p>', 'LION' ), $result->get_error_message(), 'http://ithemes.com/support/' );
97
  else if ( 'ithemes-sync-server-failed-request' == $code )
98
+ $message = sprintf( __( '<p>The iThemes Sync server was unable to process the request at this time. Please try again in a few minutes.</p><p>If you continue to experience problems, please contact <a target="_blank" href="%s">iThemes support</a>.</p>', 'LION' ), 'http://ithemes.com/support/' );
99
  else
100
  $message = $result->get_error_message();
101
 
105
  }
106
 
107
  if ( empty( $result['key'] ) ) {
108
+ $heading = __( 'The user could not be synced.', 'LION' );
109
+ $message = __( 'The sync request failed due to a server communication error. The server sent a response that did not include a authentication key.', 'LION' );
110
 
111
  $this->add_error_message( $heading, $message );
112
 
114
  }
115
 
116
  if ( empty( $result['user_id'] ) ) {
117
+ $heading = __( 'The user could not be synced.', 'LION' );
118
+ $message = __( 'The sync request failed due to a server communication error. The server sent a response that did not include a user ID.', 'LION' );
119
 
120
  $this->add_error_message( $heading, $message );
121
 
126
  $add_result = $GLOBALS['ithemes-sync-settings']->add_authentication( $result['user_id'], $data['username'], $result['key'] );
127
 
128
  if ( is_wp_error( $add_result ) ) {
129
+ $heading = __( 'The user could not be synced.', 'LION' );
130
  $message = $add_result->get_error_message();
131
 
132
  $this->add_error_message( $heading, $message );
135
  }
136
 
137
 
138
+ $heading = __( 'Woohoo! Your site has been synced.', 'LION' );
139
  $messages = array();
140
 
141
  if ( 0 == $result['quota']['available'] )
142
+ $messages[] = sprintf( __( 'Your user has now used all of the sites available to be added to Sync. More information can be found on the <a href="%s" target="_blank">iThemes membership panel</a>.', 'LION' ), $this->sync_dashboard_url );
143
  else
144
+ $messages[] = sprintf( _n( 'Your user can Sync 1 additional site.', 'Your user can sync %d additional sites.', $result['quota']['available'], 'LION' ), $result['quota']['available'] );
145
 
146
  $this->add_success_message( $heading, $messages );
147
  }
157
  $result = Ithemes_Sync_Server::deauthenticate( $data['user'], $user_details['username'], $user_details['key'] );
158
 
159
  if ( is_wp_error( $result ) && ( 'authentication' != $result->get_error_code() ) ) {
160
+ $heading = __( 'The user could not be unsynced.', 'LION' );
161
  $message = $result->get_error_message();
162
 
163
  $this->add_error_message( $heading, $message );
169
  $result = $GLOBALS['ithemes-sync-settings']->remove_authentication( $data['user'], $user_details['username'] );
170
 
171
  if ( is_wp_error( $result ) ) {
172
+ $heading = __( 'The user could not be unsynced.', 'LION' );
173
  $message = $result->get_error_message();
174
 
175
  $this->add_error_message( $heading, $message );
178
  }
179
 
180
 
181
+ $heading = __( 'The user was successfully unsynced.', 'LION' );
182
 
183
  $this->add_success_message( $heading );
184
  }
236
 
237
  $GLOBALS['ithemes-sync-settings']->update_options( $settings );
238
 
239
+ $this->messages[] = __( 'Settings saved', 'LION' );
240
  }
241
 
242
  public function show_settings() {
263
  ?>
264
  <div class="ithemes-sync-wrapper wrap">
265
  <?php if ( empty( $this->options['authentications'] ) ) : ?>
266
+ <h2><?php _e( 'Sync This Site', 'LION' ); ?></h2>
267
  <?php else : ?>
268
+ <h2><?php _e( 'iThemes Sync', 'LION' ); ?></h2>
269
  <?php endif; ?>
270
 
271
 
273
 
274
 
275
  <?php if ( ! empty( $this->options['authentications'] ) ) : ?>
276
+ <a class="ithemes-sync-button" href="<?php echo $this->sync_dashboard_url; ?>" target="_blank"><?php _e( 'Go Manage Your Synced Sites', 'LION' ); ?></a>
277
 
278
  <div class="ithemes-sync-section ithemes-sync-manage-users">
279
+ <h3><?php _e( 'Manage Synced Users', 'LION' ); ?></h3>
280
 
281
+ <p><?php _e( 'Sync allows you to sync your site with multiple users.<br>View the list of synced users below, unsync users if needed, or add additional users below.', 'LION' ); ?></p>
282
 
283
  <?php if ( ! empty( $valid_users ) ) : ?>
284
  <div class="ithemes-sync-users ithemes-sync-valid-users">
285
+ <h4><?php _e( 'Synced Users', 'LION' ); ?></h4>
286
 
287
  <ul>
288
  <?php foreach ( $valid_users as $user_id ) : ?>
297
 
298
  <?php if ( ! empty( $invalid_users ) ) : ?>
299
  <div class="ithemes-sync-users ithemes-sync-invalid-users">
300
+ <h4><?php _e( 'Invalid Users', 'LION' ); ?></h4>
301
 
302
+ <p><?php _e( 'The following users were not recognized by the server. Unsync them and resync them again to fix this error.', 'LION' ); ?></p>
303
 
304
  <ul>
305
  <?php foreach ( $invalid_users as $user_id ) : ?>
317
 
318
  <div class="ithemes-sync-section ithemes-sync-authorize">
319
  <?php if ( empty( $this->options['authentications'] ) ) : ?>
320
+ <p><?php _e( 'Enter your iThemes username & password to sync this site.', 'LION' ); ?></p>
321
  <?php else : ?>
322
+ <h3><?php _e( 'Add Users', 'LION' ); ?></h3>
323
+ <p><?php _e( 'Add additional users if more than one person will be managing updates for this site.<br>To sync an additional user, enter their iThemes username and password below.', 'LION' ); ?></p>
324
  <?php endif; ?>
325
 
326
  <form id="ithemes-sync-authenticate" enctype="multipart/form-data" method="post" action="<?php echo $this->self_url; ?>">
327
+ <label for="username"><?php _e( 'Username', 'LION' ); ?></label><br>
328
  <input type="text" id="username" name="username" value="<?php if ( $this->had_error ) echo esc_attr( $post_data['username'] ); ?>">
329
 
330
+ <label for="password"><?php _e( 'Password', 'LION' ); ?></label><br>
331
  <input type="password" id="password" name="password" value="<?php if ( $this->had_error ) echo esc_attr( $post_data['password'] ); ?>">
332
 
333
+ <input type="submit" id="submit" value="<?php _e( 'Sync', 'LION' ); ?>">
334
  <input type="hidden" name="action" value="authenticate">
335
 
336
  <?php wp_nonce_field( 'authenticate-user' ); ?>
settings.php CHANGED
@@ -130,7 +130,7 @@ class Ithemes_Sync_Settings {
130
  }
131
 
132
  if ( ! isset( $this->options['authentications'][$user_id] ) ) {
133
- return new WP_Error( 'unauthenticated-user', __( 'The user is not authenticated. Could not remove authentication for the user.', 'it-l10n-ithemes-sync' ) );
134
  }
135
 
136
 
@@ -196,7 +196,7 @@ class Ithemes_Sync_Settings {
196
  $authentication = $this->get_authentication_details( $user_id );
197
 
198
  if ( empty( $authentication ) ) {
199
- return new WP_Error( 'ithemes-sync-invalid-user', __( 'A valid user was unable to be found. A valid user is required in order to do a successful ping.', 'it-l10n-ithemes-sync' ) );
200
  }
201
 
202
 
130
  }
131
 
132
  if ( ! isset( $this->options['authentications'][$user_id] ) ) {
133
+ return new WP_Error( 'unauthenticated-user', __( 'The user is not authenticated. Could not remove authentication for the user.', 'LION' ) );
134
  }
135
 
136
 
196
  $authentication = $this->get_authentication_details( $user_id );
197
 
198
  if ( empty( $authentication ) ) {
199
+ return new WP_Error( 'ithemes-sync-invalid-user', __( 'A valid user was unable to be found. A valid user is required in order to do a successful ping.', 'LION' ) );
200
  }
201
 
202
 
social.php CHANGED
@@ -83,7 +83,7 @@ class Ithemes_Sync_Social {
83
  ?>
84
  <div id="ithemes-social" class="misc-pub-section">
85
  <div class="ithemes-social-header">
86
- <h3><?php _e('Social', 'it-l10n-ithemes-sync'); ?></h3>
87
  </div>
88
  <?php
89
  if ( 'publish' === $post->post_status ) {
@@ -99,7 +99,7 @@ class Ithemes_Sync_Social {
99
 
100
  private function _post_submitbox_content_published() {
101
  ?>
102
- <p class="it-social-notice"><?php _e('This post is already published.', 'it-l10n-ithemes-sync'); ?></p>
103
  <?php
104
  }
105
 
@@ -116,11 +116,11 @@ class Ithemes_Sync_Social {
116
  <li class="test">
117
  <input type="checkbox" name="ithemes-social[twitter][<?php echo esc_attr( $twitter_id ) ?>][send]" id="ithemes-social-twitter-<?php echo esc_attr( $twitter_id ) ?>" value="true"<?php echo $checked; ?>>
118
  <label for="ithemes-social-twitter-<?php echo esc_attr( $twitter_id ) ?>">Twitter: <em>@<?php echo esc_html( $twitter_name ) ?></em></label>
119
- <a class="ithemes-social-edit-content"><?php _e('Edit', 'it-l10n-ithemes-sync'); ?></a>
120
  <div class="ithemes-social-account-content hidden">
121
  <textarea class="widefat" name="ithemes-social[twitter][<?php echo esc_attr( $twitter_id ) ?>][content]"><?php echo esc_textarea( $default_content['twitter'] ); ?></textarea>
122
  <div class="ithemes-social-template-tags">
123
- <?php _e('Template Tags', 'it-l10n-ithemes-sync'); ?>: <br />
124
  {post_title} {post_url} {post_author}
125
  </div>
126
  <div class="ithemes-social-char-count"></div>
83
  ?>
84
  <div id="ithemes-social" class="misc-pub-section">
85
  <div class="ithemes-social-header">
86
+ <h3><?php _e('Social', 'LION'); ?></h3>
87
  </div>
88
  <?php
89
  if ( 'publish' === $post->post_status ) {
99
 
100
  private function _post_submitbox_content_published() {
101
  ?>
102
+ <p class="it-social-notice"><?php _e('This post is already published.', 'LION'); ?></p>
103
  <?php
104
  }
105
 
116
  <li class="test">
117
  <input type="checkbox" name="ithemes-social[twitter][<?php echo esc_attr( $twitter_id ) ?>][send]" id="ithemes-social-twitter-<?php echo esc_attr( $twitter_id ) ?>" value="true"<?php echo $checked; ?>>
118
  <label for="ithemes-social-twitter-<?php echo esc_attr( $twitter_id ) ?>">Twitter: <em>@<?php echo esc_html( $twitter_name ) ?></em></label>
119
+ <a class="ithemes-social-edit-content"><?php _e('Edit', 'LION'); ?></a>
120
  <div class="ithemes-social-account-content hidden">
121
  <textarea class="widefat" name="ithemes-social[twitter][<?php echo esc_attr( $twitter_id ) ?>][content]"><?php echo esc_textarea( $default_content['twitter'] ); ?></textarea>
122
  <div class="ithemes-social-template-tags">
123
+ <?php _e('Template Tags', 'LION'); ?>: <br />
124
  {post_title} {post_url} {post_author}
125
  </div>
126
  <div class="ithemes-social-char-count"></div>
verbs/db-optimization.php CHANGED
@@ -94,7 +94,7 @@ class Ithemes_Sync_Verb_DB_Optimization extends Ithemes_Sync_Verb {
94
 
95
  return array(
96
  'title' => __( 'Delete Trackback URLs' ),
97
- 'description' => esc_attr__( 'Deletes URLs added to the "pinged" and "to_ping" columns in your posts table.', 'it-l10n-ithemes-sync' ),
98
  'action' => 'delete-trackback-urls',
99
  'applies_to' => empty( $applies ) ? '0 items' : $applies . ' items',
100
  'has_items' => ! empty( $applies ),
@@ -379,7 +379,7 @@ class Ithemes_Sync_Verb_DB_Optimization extends Ithemes_Sync_Verb {
379
 
380
 
381
  private function get_last_run( $optimization_slug ) {
382
- return empty( $this->optimize_options[$optimization_slug]['last_run'] ) ? __( 'Never', 'it-l10n-ithemes-sync' ) : $this->optimize_options[$optimization_slug]['last_run'];
383
  }
384
 
385
  private function update_last_run_var( $optimization_slug ) {
94
 
95
  return array(
96
  'title' => __( 'Delete Trackback URLs' ),
97
+ 'description' => esc_attr__( 'Deletes URLs added to the "pinged" and "to_ping" columns in your posts table.', 'LION' ),
98
  'action' => 'delete-trackback-urls',
99
  'applies_to' => empty( $applies ) ? '0 items' : $applies . ' items',
100
  'has_items' => ! empty( $applies ),
379
 
380
 
381
  private function get_last_run( $optimization_slug ) {
382
+ return empty( $this->optimize_options[$optimization_slug]['last_run'] ) ? __( 'Never', 'LION' ) : $this->optimize_options[$optimization_slug]['last_run'];
383
  }
384
 
385
  private function update_last_run_var( $optimization_slug ) {
verbs/do-update.php CHANGED
@@ -39,8 +39,9 @@ class Ithemes_Sync_Verb_Do_Update extends Ithemes_Sync_Verb {
39
 
40
 
41
  $this->original_update_details = Ithemes_Sync_Functions::get_update_details( array( 'verbose' => true, 'force_refresh' => true ) );
42
-
43
-
 
44
  $response = array();
45
 
46
  if ( ! empty( $arguments['plugin'] ) ) {
@@ -57,6 +58,10 @@ class Ithemes_Sync_Verb_Do_Update extends Ithemes_Sync_Verb {
57
  return $response;
58
  }
59
 
 
 
 
 
60
  public function do_core_upgrade( $params ) {
61
  $required_fields = array(
62
  'upgrade_id',
39
 
40
 
41
  $this->original_update_details = Ithemes_Sync_Functions::get_update_details( array( 'verbose' => true, 'force_refresh' => true ) );
42
+
43
+ add_action( 'upgrader_process_complete', array( $this, 'disable_language_pack_upgrades' ), 5 );
44
+
45
  $response = array();
46
 
47
  if ( ! empty( $arguments['plugin'] ) ) {
58
  return $response;
59
  }
60
 
61
+ public function disable_language_pack_upgrades() {
62
+ remove_action( 'upgrader_process_complete', array( 'Language_Pack_Upgrader', 'async_upgrade' ), 20 );
63
+ }
64
+
65
  public function do_core_upgrade( $params ) {
66
  $required_fields = array(
67
  'upgrade_id',