Domain Mapping crashing Site on Local Development Environment

Hey folks!

I'm setting up my Local Development Environment using macOS + Homebrew and things are working fine. But when I enable the Domain Mapping Plugin (it uses 127.0.0.1 as my local IP), first it says I'm using an old version of sunrise.php (but I'm using the very latest version), and after enabling it crashes my site with the following message:

Fatal error: Uncaught Error: [] operator not supported for strings in /[Moderated]/wp-content/plugins/domain-mapping/classes/Domainmap/Module/Cdsso.php:350 Stack trace: #0 /[Moderated]/wp-includes/class-wp-hook.php(298): Domainmap_Module_Cdsso->add_query_var_for_endpoint('') #1 /[Moderated]/wp-includes/class-wp-hook.php(323): WP_Hook->apply_filters(NULL, Array) #2 /[Moderated]/wp-includes/plugin.php(453): WP_Hook->do_action(Array) #3 /[Moderated]/wp-settings.php(449): do_action('init') #4 /[Moderated]/wp-config.php(115): require_once('/Users/fabio/Si...') #5 /[Moderated]/wp-load.php(37): require_once('/Users/fabio/Si...') #6 /[Moderated]/wp-admin/admin.php(31): require_once('/Users/fabio/Si...') #7 /[Moderated]/wp-admin/network/admin.php(13): require_once('/Users/fabio/Si...') #8 /[Moderated]/wp-admin/network/settings.php(11): require_once('/Users/fabio/Si...') #9 {main} thrown in /[Moderated]/wp-content/plugins/domain-mapping/classes/Domainmap/Module/Cdsso.php on line 350.

Is there something I could do to make it work?

Maybe some Apache Module is missing?

Thank you in advance, cheers!

  • Sajid
    • DEV MAN’s Sidekick

    Hello Fabio Fava,
    Hope you are doing good today :slight_smile:

    First of all please be careful while sharing the error logs in public forums like this. Always obscure or remove the username and directory path from address. The prying eyes are always in the search of such things to get access to your site and you know what would happened next :wink:

    Secondly, the issue seems be coming from Cross Domain Single Sign On library that Domain Mapping plugin used to allow browsing dashboard pages of your network and all mapped sites easily.

    I am flagging the developer of this plugin to find out why exactly it is not allowing this. If you wish, you can just exclude this library from the plugin file and then check again. I am sure it will work after that.

    Take care and have a nice day!

    Best Regards,
    Sajid - WPMU DEV Support

  • Fabio Fava
    • WordPress DevOps

    Hey Sajid thank you very (very) much for the MODERATED thing! I forgot it!

    About my issue: is there some option I can change on my Admin Dashboard? If I delete that library it will be a temporary fix, and for now I have MU Domain Mapping working, so it's easier for me to keep it. But...

    If I can do this, or something else, to help debugging and fixing, then please let me know and I'll be glad to do whatever I can to help you guys on improving our Domain Mapping Plugin.

    Also, please let me know if is there a new version with this fixed, then I can try it out.

    Thank you in advance, cheers!

  • Fabio Fava
    • WordPress DevOps

    HI Sajid !

    When I load Domain Mapping Plugin Page (under Network/Settings), I have this message, but I'm using the file I've just copied from the right path:

    You use old version of /MY-PATH-TO/wp-content/sunrise.php file. Please, replace that file with new version which is located by following path: /MY-PATH-TO/wp-content/plugins/domain-mapping/sunrise.php.

    Any solution for that?

  • Sajid
    • DEV MAN’s Sidekick

    Hello Fabio Fava :slight_smile:

    That is strange indeed. I have already flagged the developer and passing along the updated information. As soon as I hear back from developer, I will post a reply here or developer itself post back on this ticket.

    Take care and have a nice day!

    Best Regards,
    Sajid - WPMU DEV Support

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.