<commit_before><?php
/**
 * Opengraph Protocol Metadata
 * Opengraph Specification: http://ogp.me
 *
 * Module containing functions related to Opengraph Protocol Metadata
 */


/**
 * Add contact method for Facebook author and publisher.
 */
function amt_add_facebook_contactmethod( $contactmethods ) {
    // Add Facebook Author Profile URL
    if ( !isset( $contactmethods['amt_facebook_author_profile_url'] ) ) {
        $contactmethods['amt_facebook_author_profile_url'] = __('Facebook Author Profile URL', 'add-meta-tags');
    }
    // Add Facebook Publisher Profile URL
    if ( !isset( $contactmethods['amt_facebook_publisher_profile_url'] ) ) {
        $contactmethods['amt_facebook_publisher_profile_url'] = __('Facebook Publisher Profile URL', 'add-meta-tags');
    }

    // Remove test
    // if ( isset( $contactmethods['test'] ) {
    //     unset( $contactmethods['test'] );
    // }

    return $contactmethods;
}
add_filter( 'user_contactmethods', 'amt_add_facebook_contactmethod', 10, 1 );


/**
 * Generates Opengraph metadata.
 *
 * Currently for:
 * - home page
 * - author archive
 * - content
 */
function amt_add_opengraph_metadata_head( $post ) {

    // Get the options the DB
    $options = get_option("add_meta_tags_opts");
    $do_auto_opengraph = (($options["auto_opengraph"] == "1") ? true : false );<commit_msg>Minor modification.<commit_after><?php
/**
 * Opengraph Protocol Metadata
 * Opengraph Specification: http://ogp.me
 *
 * Module containing functions related to Opengraph Protocol Metadata
 */


/**
 * Add contact method for Facebook author and publisher.
 */
function amt_add_facebook_contactmethod( $contactmethods ) {
    // Add Facebook Author Profile URL
    if ( !isset( $contactmethods['amt_facebook_author_profile_url'] ) ) {
        $contactmethods['amt_facebook_author_profile_url'] = __('Facebook author profile URL', 'add-meta-tags');
    }
    // Add Facebook Publisher Profile URL
    if ( !isset( $contactmethods['amt_facebook_publisher_profile_url'] ) ) {
        $contactmethods['amt_facebook_publisher_profile_url'] = __('Facebook publisher profile URL', 'add-meta-tags');
    }

    // Remove test
    // if ( isset( $contactmethods['test'] ) {
    //     unset( $contactmethods['test'] );
    // }

    return $contactmethods;
}
add_filter( 'user_contactmethods', 'amt_add_facebook_contactmethod', 10, 1 );


/**
 * Generates Opengraph metadata.
 *
 * Currently for:
 * - home page
 * - author archive
 * - content
 */
function amt_add_opengraph_metadata_head( $post ) {

    // Get the options the DB
    $options = get_option("add_meta_tags_opts");
    $do_auto_opengraph = (($options["auto_opengraph"] == "1") ? true : false );
{'fraction_non_alphanumeric': 0.13103192279138828, 'fraction_numerical': 0.002969561989606533, 'mean_word_length': 3.8384201077199283, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 10, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '633583', 'n_tokens_mistral': 806, 'n_tokens_neox': 815, 'n_words': 187}