/**
 * Configuration and settings management for Cart Recovery
 *
 * @package EDD\Pro\CartRecovery\Admin
 */

/**
 * Retrieves and validates the global settings object.
 *
 * @return {Object} The configuration object with defaults.
 */
export function getConfig() {
	const settings = globalThis.eddAcrAdmin || {};

	return {
		messages: settings.messages || {},
		nonce: settings.nonce || '',
		ajaxurl: settings.ajaxurl || '',
	};
}
