【发布时间】:2012-11-13 15:02:39
【问题描述】:
我正在使用 forge facebook api 打开提要对话框以将图像发布到用户墙上。如果用户单击“取消”而不是“共享”,则仍会触发成功回调。如果用户点击关闭 (x) 按钮,错误回调将正确触发。
forge.facebook.ui(
{
method: 'feed',
link: link,
picture: model.get('file').url,
name: name,
caption: caption,
description: 'Lorem Ipsum'
},
function(response) {
// Called when user clicks cancel.
forge.notification.create(
'Great!',
'Item has been posted to your wall',
function() {
},
function(error) {
forge.logging.error(JSON.stringify(error));
}
);
},
function (e) {
// Called when user closes dialogue but not on cancel.
forge.logging.info('facebook failed: ' + JSON.stringify(e));
}
);
【问题讨论】:
-
您是否检查了响应以查看它是否传递了您可以关闭的任何数据?
-
是的,我检查了响应,在这两种情况下都未定义。
标签: facebook trigger.io