Skip to content

Commit 6891744

Browse files
authored
Merge pull request #221 from BranchMetrics/fix-actual-branchjs
fix: update actual branch.js
2 parents 7d54a70 + 89dc1dc commit 6891744

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

www.es6/branch.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,24 @@ Branch.prototype.setMixpanelToken = function(token) {
8585

8686
};
8787

88+
/**
89+
* Set debug mode to simulate fresh installs.
90+
* NOTE: This must be called before initSession
91+
*
92+
* @param (Boolean) isEnabled. Default = false
93+
*
94+
* @return (Promise)
95+
*/
96+
Branch.prototype.setDebug = function (isEnabled) {
97+
98+
isEnabled = (typeof isEnabled !== 'boolean') ? false : isEnabled;
99+
100+
this.debugMode = isEnabled;
101+
102+
return execute('setDebug', [isEnabled]);
103+
104+
};
105+
88106
/**
89107
* Retrieves the install session parameters.
90108
*

0 commit comments

Comments
 (0)