@mparticle/web-double-click-kit 2.2.0 → 2.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -522,7 +522,15 @@ function initializeGoogleDFP(common, settings, isInitialized) {
522
522
  }
523
523
 
524
524
  function parseSettingsString(settingsString) {
525
- return JSON.parse(settingsString.replace(/"/g, '"'));
525
+ if (!settingsString) {
526
+ return [];
527
+ }
528
+ try {
529
+ return JSON.parse(settingsString.replace(/"/g, '"'));
530
+ } catch (error) {
531
+ console.error('Settings string contains invalid JSON');
532
+ }
533
+ return [];
526
534
  }
527
535
 
528
536
  var initialization_1 = initialization;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mparticle/web-double-click-kit",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "repository": "https://github.com/mparticle-integrations/mparticle-javascript-integration-doubleclick",
5
5
  "main": "dist/DoubleClick-Kit.common.js",
6
6
  "browser": "dist/DoubleClick-Kit.common.js",