WordPress.org

Making WordPress.org


Ignore:
Timestamp:
02/26/2018 05:38:35 AM (3 years ago)
Author:
tellyworth
Message:

2FA: make sure ajaxurl is available, not just for debug bar users.

See #77

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-two-factor/wporg-two-factor.php

    r6753 r6757  
    223223    public static function user_two_factor_options( $user ) {
    224224        wp_enqueue_script( 'two-factor-edit', plugins_url( 'js/profile-edit.js' , __FILE__ ), [ 'jquery' ], 1, true );
     225        wp_localize_script( 'two-factor-edit', 'two_factor_edit', array(
     226            'ajaxurl' => admin_url( 'admin-ajax.php' ),
     227        ) );
    225228
    226229        $key       = get_user_meta( $user->ID, Two_Factor_Totp::SECRET_META_KEY, true );
Note: See TracChangeset for help on using the changeset viewer.