| @@ 4746-4756 (lines=11) @@ | ||
| 4743 | return self::connection()->get_assumed_site_creation_date(); |
|
| 4744 | } |
|
| 4745 | ||
| 4746 | public static function apply_activation_source_to_args( &$args ) { |
|
| 4747 | list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); |
|
| 4748 | ||
| 4749 | if ( $activation_source_name ) { |
|
| 4750 | $args['_as'] = urlencode( $activation_source_name ); |
|
| 4751 | } |
|
| 4752 | ||
| 4753 | if ( $activation_source_keyword ) { |
|
| 4754 | $args['_ak'] = urlencode( $activation_source_keyword ); |
|
| 4755 | } |
|
| 4756 | } |
|
| 4757 | ||
| 4758 | function build_reconnect_url( $raw = false ) { |
|
| 4759 | $url = wp_nonce_url( self::admin_url( 'action=reconnect' ), 'jetpack-reconnect' ); |
|
| @@ 1097-1111 (lines=15) @@ | ||
| 1094 | * @param Array $args arguments that need to have the source added. |
|
| 1095 | * @return Array $amended arguments. |
|
| 1096 | */ |
|
| 1097 | public static function apply_activation_source_to_args( $args ) { |
|
| 1098 | list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); |
|
| 1099 | ||
| 1100 | if ( $activation_source_name ) { |
|
| 1101 | // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode |
|
| 1102 | $args['_as'] = urlencode( $activation_source_name ); |
|
| 1103 | } |
|
| 1104 | ||
| 1105 | if ( $activation_source_keyword ) { |
|
| 1106 | // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode |
|
| 1107 | $args['_ak'] = urlencode( $activation_source_keyword ); |
|
| 1108 | } |
|
| 1109 | ||
| 1110 | return $args; |
|
| 1111 | } |
|
| 1112 | ||
| 1113 | /** |
|
| 1114 | * Returns the callable that would be used to generate secrets. |
|