• Hello,

    I noticed an undefined was logged in the js console by this plugins admin.js script;
    admin.js?ver=2.4.8:100 undefined

    Looking at the code it’s this line that does the logging;

    function show_hide_select2box($, selected_type) {
        console.log(selected_type);

    This function is called inside the document ready here;
    show_hide_select2box($, $(‘select#fieldtype’).val());

    Depending on the scripts use can be isolated to only enqueue on BP Profile Edit pages.

    Or can wrap that show_hide_select2box call with a length check on $(‘select#fieldtype’) as it shouldn’t be executed if this doesn’t exist.

    Thanks

    https://www.ads-software.com/plugins/buddypress-xprofile-custom-fields-type/

  • The topic ‘JS undefined in console’ is closed to new replies.