Code Duplication    Length = 4-4 lines in 2 locations

packages/jitm/src/class-pre-connection-jitm.php 2 locations

@@ 114-117 (lines=4) @@
111
112
			$envelope->url = add_query_arg( $url_params, 'https://jetpack.com/redirect/' );
113
114
			if ( $envelope->cta['hook'] ) {
115
				$envelope->url = apply_filters( 'jitm_' . $envelope->cta['hook'], $envelope->url );
116
				unset( $envelope->cta['hook'] );
117
			}
118
119
			if ( isset( $envelope->content['hook'] ) ) {
120
				$envelope->content = apply_filters( 'jitm_' . $envelope->content['hook'], $envelope->content );
@@ 119-122 (lines=4) @@
116
				unset( $envelope->cta['hook'] );
117
			}
118
119
			if ( isset( $envelope->content['hook'] ) ) {
120
				$envelope->content = apply_filters( 'jitm_' . $envelope->content['hook'], $envelope->content );
121
				unset( $envelope->content['hook'] );
122
			}
123
124
			// No point in showing an empty message.
125
			if ( empty( $envelope->content['message'] ) ) {