Code Duplication    Length = 5-5 lines in 2 locations

classes/PodsAdmin.php 1 location

@@ 3097-3101 (lines=5) @@
3094
						'view' => 'view',
3095
					);
3096
3097
					foreach ( $available_actions as $action ) {
3098
						if ( ! in_array( $action, $actions_enabled, true ) ) {
3099
							$actions_disabled[ $action ] = $action;
3100
						}
3101
					}
3102
3103
					if ( ! in_array( 'export', $actions_disabled, true ) ) {
3104
						$capabilities[] = 'pods_export_' . $pod['name'];

classes/Pods.php 1 location

@@ 4262-4266 (lines=5) @@
4259
					'view' => 'view',
4260
				);
4261
4262
				foreach ( $available_actions as $action ) {
4263
					if ( ! in_array( $action, $actions_enabled, true ) ) {
4264
						$actions_disabled[ $action ] = $action;
4265
					}
4266
				}
4267
			} else {
4268
				$actions_disabled = array(
4269
					'duplicate' => 'duplicate',