RIFT-14942: added check for loggingEvents
[osm/UI.git] / skyquake / plugins / logging / api / transforms.js
index 5f65010..2e2b8dc 100644 (file)
@@ -168,7 +168,7 @@ LoggingConfigEncoder.prototype.denyEvents = function(data) {
  * or absence of the { "allow": { "duplicate": "events" }} key/value hierarchy
  */
 LoggingConfigEncoder.prototype.allow = function(data) {
-  if (data.allowDuplicateEvents.toUpperCase() == "TRUE") {
+  if (data.allowDuplicateEvents && data.allowDuplicateEvents.toUpperCase() == "TRUE") {
     return { duplicate: "events" };
   } else {
     return null;