Skip to content

Undefined index: master_site_setting in /wp-content/plugins/multisite-post-duplicator/addons/restrictSites-mpd-addon.php on line 325 #64

@Jon007

Description

@Jon007

In certain circumstances it is possible to produce:
Notice: Undefined index: master_site_setting in /wp-content/plugins/multisite-post-duplicator/addons/restrictSites-mpd-addon.php on line 325

This can be resolved in this case by testing if the option is set:

	$options = get_option( 'mdp_settings' );
	if ( isset( $options[ 'master_site_setting' ] ) ) {
		$master_id = $options[ 'master_site_setting' ];

though a better solution is to ensure default options are always available plugin-wide

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions