fix(RestWrite): make method async as expected in usage (#6025)
The method `createSessionToken` in RestWrite.js is assumed to always return a promise (see Line 961 in `handleFollowUp`) - this was throwing an error `cannot read 'then' of undefined`. This simply one word change fixes that error.
This commit is contained in:
committed by
Antonio Davi Macedo Coelho de Castro
parent
6497ec72ed
commit
618fe37c5a
@@ -872,7 +872,7 @@ RestWrite.prototype.createSessionTokenIfNeeded = function() {
|
||||
return this.createSessionToken();
|
||||
};
|
||||
|
||||
RestWrite.prototype.createSessionToken = function() {
|
||||
RestWrite.prototype.createSessionToken = async function() {
|
||||
// cloud installationId from Cloud Code,
|
||||
// never create session tokens from there.
|
||||
if (this.auth.installationId && this.auth.installationId === 'cloud') {
|
||||
|
||||
Reference in New Issue
Block a user