Code Duplication    Length = 7-7 lines in 2 locations

modules/theme-tools/content-options/blog-display.php 2 locations

@@ 77-83 (lines=7) @@
74
 * Display Excerpt instead of Content.
75
 */
76
function jetpack_the_content_to_the_excerpt( $content ) {
77
	if ( is_home() || is_archive() ) {
78
		if ( post_password_required() ) {
79
			$content = sprintf( '<p>%s</p>', esc_html__( 'There is no excerpt because this is a protected post.', 'jetpack' ) );
80
		} else {
81
			$content = jetpack_blog_display_custom_excerpt( $content );
82
		}
83
	}
84
	return $content;
85
}
86
@@ 115-121 (lines=7) @@
112
 */
113
function jetpack_the_content_customizer( $content ) {
114
	$class = jetpack_the_content_customizer_class();
115
	if ( is_home() || is_archive() ) {
116
		if ( post_password_required() ) {
117
			$excerpt = sprintf( '<p>%s</p>', esc_html__( 'There is no excerpt because this is a protected post.', 'jetpack' ) );
118
		} else {
119
			$excerpt = jetpack_blog_display_custom_excerpt( $content );
120
		}
121
	}
122
	if ( empty( $excerpt ) ) {
123
		return $content;
124
	} else {