Completed
Push — staging ( 095f10...309c56 )
by
unknown
18:49
created
admin/class-yikes-inc-easy-mailchimp-extender-admin.php 1 patch
Indentation   +67 added lines, -67 removed lines patch added patch discarded remove patch
@@ -581,7 +581,7 @@  discard block
 block discarded – undo
581 581
 			yikes_easy_mailchimp_stop_bugging_me()
582 582
 			Remove the Review us notification when user clicks 'Dismiss'
583 583
 			@since v3.1.1
584
-		*/
584
+		 */
585 585
 		public function yikes_easy_mailchimp_stop_bugging_me() {
586 586
 			if ( isset( $_GET['yikes_easy_mc_icons_nobug'] ) && (int) filter_var( $_GET['yikes_easy_mc_icons_nobug'], FILTER_SANITIZE_NUMBER_INT ) === 1 ) {
587 587
 				add_option( 'yikes_easy_mailchimp_review_stop_bugging_me', true );
@@ -843,9 +843,9 @@  discard block
 block discarded – undo
843 843
 	}
844 844
 
845 845
 	/**
846
-	*	Register our admin pages
847
-	*	used to display data back to the user
848
-	**/
846
+	 *	Register our admin pages
847
+	 *	used to display data back to the user
848
+	 **/
849 849
 	public function register_admin_pages() {
850 850
 
851 851
 		/* Top Level Menu 'Easy Mailchimp' */
@@ -964,28 +964,28 @@  discard block
 block discarded – undo
964 964
 	}
965 965
 
966 966
 	/**
967
-	* Generate Us Easy Mailchimp Manage Forms Page
968
-	*
969
-	* @since    1.0.0
970
-	*/
967
+	 * Generate Us Easy Mailchimp Manage Forms Page
968
+	 *
969
+	 * @since    1.0.0
970
+	 */
971 971
 	function generateManageFormsPage() {
972 972
 		require_once YIKES_MC_PATH . 'admin/partials/menu/manage-forms.php'; // include our manage forms page
973 973
 	}
974 974
 
975 975
 	/**
976
-	* Generate Us Easy Mailchimp Manage Lists Page
977
-	*
978
-	* @since    1.0.0
979
-	*/
976
+	 * Generate Us Easy Mailchimp Manage Lists Page
977
+	 *
978
+	 * @since    1.0.0
979
+	 */
980 980
 	function generateManageListsPage() {
981 981
 		require_once YIKES_MC_PATH . 'admin/partials/menu/manage-lists.php'; // include our lists page
982 982
 	}
983 983
 
984 984
 	/**
985
-	* Generate Us Easy Mailchimp Support Page
986
-	*
987
-	* @since    1.0.0
988
-	*/
985
+	 * Generate Us Easy Mailchimp Support Page
986
+	 *
987
+	 * @since    1.0.0
988
+	 */
989 989
 	function generateSupportPage() {
990 990
 
991 991
 		wp_enqueue_script( 'yikes-inc-easy-mailchimp-extender-support-scripts', plugin_dir_url( __FILE__ ) . 'js/support.js', array( 'jquery' ), $this->version, false );
@@ -993,37 +993,37 @@  discard block
 block discarded – undo
993 993
 	}
994 994
 
995 995
 	/**
996
-	* Generate Us Easy Mailchimp Edit Form Page
997
-	*
998
-	* @since    1.0.0
999
-	*/
996
+	 * Generate Us Easy Mailchimp Edit Form Page
997
+	 *
998
+	 * @since    1.0.0
999
+	 */
1000 1000
 	function generateEditFormPage() {
1001 1001
 		require_once YIKES_MC_PATH . 'admin/partials/edit-form.php'; // include our options page
1002 1002
 	}
1003 1003
 
1004 1004
 	/**
1005
-	* Generate Us Easy Mailchimp View List Page
1006
-	*
1007
-	* @since    1.0.0
1008
-	*/
1005
+	 * Generate Us Easy Mailchimp View List Page
1006
+	 *
1007
+	 * @since    1.0.0
1008
+	 */
1009 1009
 	function generateViewListPage() {
1010 1010
 		require_once YIKES_MC_PATH . 'admin/partials/view-list.php'; // include our options page
1011 1011
 	}
1012 1012
 
1013 1013
 	/**
1014
-	* Generate Us Easy Mailchimp View User Page
1015
-	*
1016
-	* @since    1.0.0
1017
-	*/
1014
+	 * Generate Us Easy Mailchimp View User Page
1015
+	 *
1016
+	 * @since    1.0.0
1017
+	 */
1018 1018
 	function generateViewUserPage() {
1019 1019
 		require_once YIKES_MC_PATH . 'admin/partials/view-user.php'; // include our options page
1020 1020
 	}
1021 1021
 
1022 1022
 	/**
1023
-	*	Register our plugin settings, and display them on our settings page
1024
-	*
1025
-	* @since v.5.4
1026
-	**/
1023
+	 *	Register our plugin settings, and display them on our settings page
1024
+	 *
1025
+	 * @since v.5.4
1026
+	 **/
1027 1027
 	function yikes_easy_mc_settings_init() {
1028 1028
 
1029 1029
 		/* Register General Settings Section */
@@ -1167,9 +1167,9 @@  discard block
 block discarded – undo
1167 1167
 	}
1168 1168
 
1169 1169
 	/**
1170
-	*	Options Sanitization & Validation
1171
-	*	@since complete re-write
1172
-	**/
1170
+	 *	Options Sanitization & Validation
1171
+	 *	@since complete re-write
1172
+	 **/
1173 1173
 	function yikes_mc_validate_api_key( $input ) {
1174 1174
 		if ( $input === '' ) {
1175 1175
 			update_option( 'yikes-mc-api-validation', 'invalid_api_key' );
@@ -1201,20 +1201,20 @@  discard block
 block discarded – undo
1201 1201
 	}
1202 1202
 
1203 1203
 	/**
1204
-	* Generate Us Easy Forms for Mailchimp Options Page
1205
-	*
1206
-	* @since    1.0.0
1207
-	*/
1204
+	 * Generate Us Easy Forms for Mailchimp Options Page
1205
+	 *
1206
+	 * @since    1.0.0
1207
+	 */
1208 1208
 	function generatePageOptions() {
1209 1209
 		require_once YIKES_MC_PATH . 'admin/partials/menu/options.php'; // include our options page
1210 1210
 	}
1211 1211
 
1212 1212
 	/**
1213
-	*	Check if users API key is valid, if not
1214
-	*	this function will apply a disabled attribute
1215
-	*	to form fields. (input, dropdowns, buttons etc.)
1216
-	* 	@since v5.5 re-write
1217
-	**/
1213
+	 *	Check if users API key is valid, if not
1214
+	 *	this function will apply a disabled attribute
1215
+	 *	to form fields. (input, dropdowns, buttons etc.)
1216
+	 * 	@since v5.5 re-write
1217
+	 **/
1218 1218
 	public function is_user_mc_api_valid_form( $echo = true ) {
1219 1219
 		if ( $echo == true ) {
1220 1220
 			if ( get_option( 'yikes-mc-api-validation', 'invalid_api_key' ) == 'invalid_api_key' ) {
@@ -1240,12 +1240,12 @@  discard block
 block discarded – undo
1240 1240
 		*	- http://stackoverflow.com/questions/6661530/php-multi-dimensional-array-search
1241 1241
 		*/
1242 1242
 		function findMCListID($id, $array) {
1243
-		   foreach ($array as $key => $val) {
1244
-			   if ($val['id'] === $id) {
1245
-				   return $key;
1246
-			   }
1247
-		   }
1248
-		   return null;
1243
+			foreach ($array as $key => $val) {
1244
+				if ($val['id'] === $id) {
1245
+					return $key;
1246
+				}
1247
+			}
1248
+			return null;
1249 1249
 		} // end
1250 1250
 
1251 1251
 		/*
@@ -1420,13 +1420,13 @@  discard block
 block discarded – undo
1420 1420
 				<?php
1421 1421
 
1422 1422
 					/**
1423
-					*	yikes-mailchimp-excluded-redirect-post-types
1424
-					*
1425
-					*	Filter the post types that will not show on the redirect list dropdown.
1426
-					*
1427
-					* 	@param array | $excluded_post_types | The array of default excluded post types
1428
-					*	@return array| $excluded_post_types | The array of user-defined excluded post types
1429
-					*/
1423
+					 *	yikes-mailchimp-excluded-redirect-post-types
1424
+					 *
1425
+					 *	Filter the post types that will not show on the redirect list dropdown.
1426
+					 *
1427
+					 * 	@param array | $excluded_post_types | The array of default excluded post types
1428
+					 *	@return array| $excluded_post_types | The array of user-defined excluded post types
1429
+					 */
1430 1430
 					$excluded_post_types = array( 'attachment', 'revision', 'nav_menu_item', 'shop_order', 'shop_order_refund', 'custom_css', 'customize_changeset', 'forum', 'topic', 'reply' );
1431 1431
 					$excluded_post_types = apply_filters( 'yikes-mailchimp-excluded-redirect-post-types', $excluded_post_types );
1432 1432
 
@@ -1556,9 +1556,9 @@  discard block
 block discarded – undo
1556 1556
 			}
1557 1557
 
1558 1558
 			/**
1559
-			*	Custom action hook for our extensions to hook into
1560
-			*	@parameter	get_current_screen()	current screen information
1561
-			*/
1559
+			 *	Custom action hook for our extensions to hook into
1560
+			 *	@parameter	get_current_screen()	current screen information
1561
+			 */
1562 1562
 			do_action( 'yikes-mailchimp-admin-sidebar', get_current_screen() );
1563 1563
 
1564 1564
 		}
@@ -2508,13 +2508,13 @@  discard block
 block discarded – undo
2508 2508
 			$result = $this->form_interface->create_form( $form_data );
2509 2509
 
2510 2510
 			/**
2511
-			* `yikes-mailchimp-after-duplicating-form`
2512
-			*
2513
-			* @param $post_id_to_clone | int   | ID of the original form
2514
-			* @param $result           | mixed | ID of the new form OR false if the operation failed
2515
-			* @param $form_data        | array | Array of the form data
2516
-			*
2517
-			*/
2511
+			 * `yikes-mailchimp-after-duplicating-form`
2512
+			 *
2513
+			 * @param $post_id_to_clone | int   | ID of the original form
2514
+			 * @param $result           | mixed | ID of the new form OR false if the operation failed
2515
+			 * @param $form_data        | array | Array of the form data
2516
+			 *
2517
+			 */
2518 2518
 			do_action( 'yikes-mailchimp-after-duplicating-form', $post_id_to_clone, $result, $form_data );
2519 2519
 
2520 2520
 			if ( false === $result ) {
Please login to merge, or discard this patch.