Skip to content

Commit

Permalink
addressed review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ruchiramoitra committed Jul 30, 2020
1 parent 3171728 commit a6b0100
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
10 changes: 3 additions & 7 deletions integrations/Bugsnag/browser.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
import logger from "../../utils/logUtil";
import ScriptLoader from "../ScriptLoader";
import {
MAX_WAIT_FOR_INTEGRATION_LOAD,
INTEGRATION_LOAD_CHECK_INTERVAL
} from "../../utils/constants";

class Bugsnag {
constructor(config) {
Expand All @@ -27,7 +23,7 @@ import {
}

initBugsnagClient() {
if (window.bugsnag !== undefined && window.bugsnag !== void 0) {
if (window.bugsnag !== undefined) {
window.bugsnagClient = window.bugsnag(this.apiKey);
window.bugsnagClient.releaseStage = this.releaseStage;
clearInterval(this.setIntervalHandler);
Expand All @@ -47,11 +43,11 @@ import {
identify(rudderElement) {
let traits = rudderElement.message.context.traits;
let traitsFinal = {
id: rudderElement.message.userId,
id: rudderElement.message.userId || rudderElement.message.anonymousId,
name: traits.name,
email: traits.email
};
console.log(traitsFinal);

window.bugsnagClient.user = traitsFinal;
window.bugsnagClient.notify(new Error("error in identify"));
}
Expand Down
1 change: 1 addition & 0 deletions integrations/integration_cname.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ const commonNames = {
VWO: "VWO",
OPTIMIZELY: "OPTIMIZELY",
Optimizely: "OPTIMIZELY",
BUGSNAG: "BUGSNAG",
};

export { commonNames };

0 comments on commit a6b0100

Please sign in to comment.