-
-
Save derak-kilgo/e5f9ad6a3f4e4c9af9c3d515016e5d01 to your computer and use it in GitHub Desktop.
WordPress :: Divi Builder :: Disable Google Maps
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @package Divi_Disable_Maps | |
* @version 1.0 | |
*/ | |
/* | |
Plugin Name: Divi Disable Maps | |
Description: Enable only if you are not using the map module. Fixes "Google Maps JavaScript API warning: NoApiKeys" wanring in the console. | |
Author: lots0logs | |
Author URI: https://gist.github.com/lots0logs/67d639070dc54505eef1 | |
Version: 1.0 | |
Text Domain: divi-disable-maps | |
*/ | |
function divi_disable_maps_et_pb_admin_scripts_styles() { | |
wp_dequeue_script( 'google-maps-api' ); | |
} | |
add_action( 'admin_enqueue_scripts', 'divi_disable_maps_et_pb_admin_scripts_styles', 99, 1 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment