gmail插件中的怪异运行时错误-MessageAccessToken错误 [英] A weird run time error in gmail addon - MessageAccessToken error

查看:60
本文介绍了gmail插件中的怪异运行时错误-MessageAccessToken错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

插件运行正常.在某个时间点,此错误开始显示仅适用于一个用户.其他用户则没有这种体验.

The add on was running finely. At some point of time , this error started showing up only for one user. Other users dont experience this.

function buildAddOn(e) { //Add on trigger function
  var card = CardService.newCardBuilder();
  card.setHeader(CardService.newCardHeader().setTitle('Home'));
  var section = CardService.newCardSection();
  section.addWidget(CardService.newTextParagraph().setText("hello world"));
  return card.build();
}

不过,我没有一个名为Storage的文件.

I do not have a file called Storage, though.

"SyntaxError:意外令牌:u [行:60,函数:,文件:存储]"

"SyntaxError: Unexpected token: u [line: 60, function: , file: Storage]"

更新 与此有关

 GmailApp.setCurrentMessageAccessToken(e.messageMetadata.accessToken)

更新2:Gmail UI对象e未定义

这不应是未定义的.这是Gmail UI提供的对象.

This is not supposed to be undefined. This is an object that is provided by the Gmail UI.

console.log(e) //undefined

更新3 相同的插件对于其他用户而言运行完美.

Update 3 The same addon runs perfectly for other users.

推荐答案

空的缓存和硬重载浏览器,此错误将消失(但请记住,这不是跳过用户端错误的正确方法)

Empty cache and Hard reload browser this error will disappear (But keep in mind that it's not proper way to skip error for user end)

这篇关于gmail插件中的怪异运行时错误-MessageAccessToken错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆