<commit_before><?php
/**
 * Class AMP_Comments_Sanitizer.
 *
 * @package AMP
 */

/**
 * Class AMP_Link_Sanitizer
 *
 * Adapts links for AMP-to-AMP navigation in Transitional mode.
 *
 * Adapted from https://gist.github.com/westonruter/f9ee9ea717d52471bae092879e3d52b0
 */
class AMP_Link_Sanitizer extends AMP_Base_Sanitizer {

	/**
	 * Default A2A meta tag content.
	 *
	 * @var string
	 */
	const DEFAULT_A2A_META_CONTENT = 'AMP-Redirect-To; AMP.navigateTo';

	/**
	 * Placeholder for default args, to be set in child classes.
	 *
	 * @var array
	 */
	protected $DEFAULT_ARGS = [ // phpcs:ignore WordPress.NamingConventions.ValidVariableName.PropertyNotSnakeCase
		'add_amphtml_rel'   => true,
		'add_query_vars'    => true, // Set to false when in native mode. Overridden in \AMP_To_AMP\filter_content_sanitizers().
		'has_theme_support' => false, // Set to true when theme has 'amp' support. Overridden in \AMP_To_AMP\filter_content_sanitizers().
		'add_a2a_meta'      => self::DEFAULT_A2A_META_CONTENT, // Only relevant when theme support is present.
	];

	/**
	 * Home host.
	 *
	 * @var string
	 */
	protected $home_host;
<commit_msg>Only add query vars in Transitional mode<commit_after><?php
/**
 * Class AMP_Comments_Sanitizer.
 *
 * @package AMP
 */

/**
 * Class AMP_Link_Sanitizer
 *
 * Adapts links for AMP-to-AMP navigation in Transitional mode.
 *
 * Adapted from https://gist.github.com/westonruter/f9ee9ea717d52471bae092879e3d52b0
 */
class AMP_Link_Sanitizer extends AMP_Base_Sanitizer {

	/**
	 * Default A2A meta tag content.
	 *
	 * @var string
	 */
	const DEFAULT_A2A_META_CONTENT = 'AMP-Redirect-To; AMP.navigateTo';

	/**
	 * Placeholder for default args, to be set in child classes.
	 *
	 * @var array
	 */
	protected $DEFAULT_ARGS = [ // phpcs:ignore WordPress.NamingConventions.ValidVariableName.PropertyNotSnakeCase
		'add_amphtml_rel'   => true,
		'add_query_vars'    => false, // Only set to true when in Transitional mode.
		'has_theme_support' => false, // Set to true when theme has 'amp' support. Overridden in \AMP_To_AMP\filter_content_sanitizers().
		'add_a2a_meta'      => self::DEFAULT_A2A_META_CONTENT, // Only relevant when theme support is present.
	];

	/**
	 * Home host.
	 *
	 * @var string
	 */
	protected $home_host;

{'fraction_non_alphanumeric': 0.11346578366445915, 'fraction_numerical': 0.02119205298013245, 'mean_word_length': 3.7012448132780085, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 11, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3306789', 'n_tokens_mistral': 857, 'n_tokens_neox': 782, 'n_words': 186}