@@ 5133-5143 (lines=11) @@ | ||
5130 | return self::connection()->get_assumed_site_creation_date(); |
|
5131 | } |
|
5132 | ||
5133 | public static function apply_activation_source_to_args( &$args ) { |
|
5134 | list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); |
|
5135 | ||
5136 | if ( $activation_source_name ) { |
|
5137 | $args['_as'] = urlencode( $activation_source_name ); |
|
5138 | } |
|
5139 | ||
5140 | if ( $activation_source_keyword ) { |
|
5141 | $args['_ak'] = urlencode( $activation_source_keyword ); |
|
5142 | } |
|
5143 | } |
|
5144 | ||
5145 | function build_reconnect_url( $raw = false ) { |
|
5146 | $url = wp_nonce_url( self::admin_url( 'action=reconnect' ), 'jetpack-reconnect' ); |
@@ 1353-1367 (lines=15) @@ | ||
1350 | * @param array $args arguments that need to have the source added. |
|
1351 | * @return array $amended arguments. |
|
1352 | */ |
|
1353 | public static function apply_activation_source_to_args( $args ) { |
|
1354 | list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); |
|
1355 | ||
1356 | if ( $activation_source_name ) { |
|
1357 | // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode |
|
1358 | $args['_as'] = urlencode( $activation_source_name ); |
|
1359 | } |
|
1360 | ||
1361 | if ( $activation_source_keyword ) { |
|
1362 | // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode |
|
1363 | $args['_ak'] = urlencode( $activation_source_keyword ); |
|
1364 | } |
|
1365 | ||
1366 | return $args; |
|
1367 | } |
|
1368 | ||
1369 | /** |
|
1370 | * Generates two secret tokens and the end of life timestamp for them. |