Code Duplication    Length = 11-20 lines in 2 locations

includes/acf/api/api-helpers.php 1 location

@@ 920-939 (lines=20) @@
917
	
918
	
919
	// add extra registered sizes
920
	if( !empty($all_sizes) ) {
921
		
922
		foreach( $all_sizes as $size ) {
923
			
924
			// bail early if already in array
925
			if( isset($sizes[ $size ]) ) {
926
			
927
				continue;
928
				
929
			}
930
			
931
			
932
			// append to array
933
			$label = str_replace('-', ' ', $size);
934
			$label = ucwords( $label );
935
			$sizes[ $size ] = $label;
936
			
937
		}
938
		
939
	}
940
	
941
	
942
	// add sizes

includes/acf/fields/wysiwyg.php 1 location

@@ 361-371 (lines=11) @@
358
		$toolbars = $this->get_toolbars();
359
		$choices = array();
360
		
361
		if( !empty($toolbars) ) {
362
		
363
			foreach( $toolbars as $k => $v ) {
364
				
365
				$label = $k;
366
				$name = sanitize_title( $label );
367
				$name = str_replace('-', '_', $name);
368
				
369
				$choices[ $name ] = $label;
370
			}
371
		}
372
		
373
		
374
		// default_value