@@ 5136-5146 (lines=11) @@ | ||
5133 | return self::connection()->get_assumed_site_creation_date(); |
|
5134 | } |
|
5135 | ||
5136 | public static function apply_activation_source_to_args( &$args ) { |
|
5137 | list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); |
|
5138 | ||
5139 | if ( $activation_source_name ) { |
|
5140 | $args['_as'] = urlencode( $activation_source_name ); |
|
5141 | } |
|
5142 | ||
5143 | if ( $activation_source_keyword ) { |
|
5144 | $args['_ak'] = urlencode( $activation_source_keyword ); |
|
5145 | } |
|
5146 | } |
|
5147 | ||
5148 | function build_reconnect_url( $raw = false ) { |
|
5149 | $url = wp_nonce_url( self::admin_url( 'action=reconnect' ), 'jetpack-reconnect' ); |
@@ 1370-1384 (lines=15) @@ | ||
1367 | * @param array $args arguments that need to have the source added. |
|
1368 | * @return array $amended arguments. |
|
1369 | */ |
|
1370 | public static function apply_activation_source_to_args( $args ) { |
|
1371 | list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); |
|
1372 | ||
1373 | if ( $activation_source_name ) { |
|
1374 | // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode |
|
1375 | $args['_as'] = urlencode( $activation_source_name ); |
|
1376 | } |
|
1377 | ||
1378 | if ( $activation_source_keyword ) { |
|
1379 | // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode |
|
1380 | $args['_ak'] = urlencode( $activation_source_keyword ); |
|
1381 | } |
|
1382 | ||
1383 | return $args; |
|
1384 | } |
|
1385 | ||
1386 | /** |
|
1387 | * Generates two secret tokens and the end of life timestamp for them. |