Skip to content

Commit bce3814

Browse files
committed
Merge pull request #104 from aisk/master
add warning when reinitialize
2 parents 8c54df4 + e260506 commit bce3814

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/utils.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,9 @@
128128
* @param {String} applicationKey Your AV Application Key
129129
*/
130130
AV._initialize = function(applicationId, applicationKey, masterKey) {
131+
if (AV.applicationId !== undefined) {
132+
console.warn('AVOSCloud SDK is already initialized, please don\'t reinitialize it.');
133+
}
131134
AV.applicationId = applicationId;
132135
AV.applicationKey = applicationKey;
133136
AV.masterKey = masterKey;

0 commit comments

Comments
 (0)