Code Duplication    Length = 9-9 lines in 2 locations

components/Templates/includes/functions-view_template.php 2 locations

@@ 133-141 (lines=9) @@
130
			if ( $field_data == $atts[ 'value' ] ) {
131
				// IF statement true, use [IF] content as template
132
				$template = $pod->do_magic_tags( $code[ 0 ] );
133
			} else {
134
				if ( isset( $code[ 1 ] ) ) {
135
					// Switch [else] portion of shortcode into active content
136
					$template = $pod->do_magic_tags( $code[ 1 ] );
137
				} else {
138
					// Value did not match, nothing should be displayed
139
					$template = '';
140
				}
141
			}
142
		} else {
143
			// Field exists and is not empty, use [if] content
144
			$template = $pod->do_magic_tags( $code[ 0 ] );
@@ 146-154 (lines=9) @@
143
			// Field exists and is not empty, use [if] content
144
			$template = $pod->do_magic_tags( $code[ 0 ] );
145
		}
146
	} else {
147
		// No 'field' value, switch to [else] content
148
		if ( isset( $code[ 1 ] ) ) {
149
			$template = $pod->do_magic_tags( $code[ 1 ] );
150
		} else {
151
			// No 'field' value and no [else] tag
152
			$template = '';
153
		}
154
	}
155
	if ( defined( 'PODS_SHORTCODE_ALLOW_SUB_SHORTCODES' ) && PODS_SHORTCODE_ALLOW_SUB_SHORTCODES ) {
156
		// Allow all nested shortcodes
157
		$template = do_shortcode( $template );