• Resolved shorelinechrism

    (@shorelinechrism)


    Is there some kind of constant that I can use in my wp-config.php in certain environments, like a local dev environment, where I can turn off hummingbird functionality entirely? Or maybe a few constants that turn off each piece?

    I searched the plugin code and nowhere does this plugin make use of wp_get_environment_type function. Are there plans to integrate this newer function into this plugin?

    Running this plugin locally or on staging has become problematic since for asset optimization the site PATH is used in the settings and in a local/dev environment the PATH changes. I could search/replace for the path (which is what I’m doing) but seeing as this plugin is meant for production environments, turning it off via constant would be an easy thing for me to add to my environments’ wp-config.php files.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Nithin – WPMU DEV Support

    (@wpmudevsupport11)

    Hi @shorelinechrism,

    I’m afraid, there isn’t any defines specifically for such a workflow. We have found the plugin should work fine in most use cases in localhost and staging. Is there an example regarding what type of path doesn’t work in localhost or staging for you?

    At the moment, there is an option to disable Asset Optimization via the plugin dashboard under Hummingbird > Asset Optimization > Settings > Deactivate.

    But you can also try the following filter which should disable Asset Optimization:

    add_filter( 'wp_hummingbird_is_active_module_minify', '__return_false' );

    The above code can be added as a mu-plugins. Please check this link on how to implement the above code as a mu-plugins:
    https://premium.wpmudev.org/docs/using-wordpress/installing-wordpress-plugins/#installing-mu-plugins

    Please do check and let us know whether the above fits your use case.

    Kind Regards,
    Nithin

    Plugin Support Patrick – WPMU DEV Support

    (@wpmudevsupport12)

    Hi @shorelinechrism

    I hope you are doing well and safe!

    We haven’t heard from you in a while, I’ll mark this thread as resolved.

    Feel free to let us know if you have any additional questions or problems.

    Best Regards
    Patrick Freitas

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Disable hummingbird for local/staging environments’ is closed to new replies.