Code Duplication    Length = 7-9 lines in 2 locations

classes/PodsUI.php 2 locations

@@ 1430-1438 (lines=9) @@
1427
				}
1428
			}//end if
1429
1430
			if ( false !== $this->searchable ) {
1431
				if ( 'search' !== $which && isset( $this->fields['search'] ) && ! empty( $this->fields['search'] ) ) {
1432
					$this->fields['search'] = $this->setup_fields( $this->fields['search'], 'search' );
1433
				} else {
1434
					$this->fields['search'] = $fields;
1435
				}
1436
			} else {
1437
				$this->fields['search'] = false;
1438
			}
1439
1440
			if ( ! in_array( 'export', $this->actions_disabled ) ) {
1441
				if ( 'export' !== $which && isset( $this->fields['export'] ) && ! empty( $this->fields['export'] ) ) {
@@ 1446-1452 (lines=7) @@
1443
				}
1444
			}
1445
1446
			if ( ! in_array( 'reorder', $this->actions_disabled ) && false !== $this->reorder['on'] ) {
1447
				if ( 'reorder' !== $which && isset( $this->fields['reorder'] ) && ! empty( $this->fields['reorder'] ) ) {
1448
					$this->fields['reorder'] = $this->setup_fields( $this->fields['reorder'], 'reorder' );
1449
				} else {
1450
					$this->fields['reorder'] = $fields;
1451
				}
1452
			}
1453
		}//end if
1454
1455
		return $this->do_hook( 'setup_fields', $fields, $which, $init );