安装Firefox扩展时,addon.repository Addon为null

时间:2014-03-25 14:09:05

标签: firefox firefox-addon kango-framework

我使用kango-framework创建了一个扩展程序,它在Chrome和Opera 20中运行正常,但在Firefox 27或28上安装时,我收到错误“aAddon._repositoryAddon is null”。 有什么猜测?感谢

1 个答案:

答案 0 :(得分:0)

我认为aAddon没有_repositoryAddon作为参数。通过包括Console.jsm然后转到console.log('aAddon',aAddon)来查找。 (尝试只执行console.log可能已包含Console.jsm)。然后打开浏览器控制台。然后在浏览器控制台中,应该是最新的条目,然后在它旁边的链接上找到你的aAddon msg,点击它,然后在变量查看器中打开它。在那里你可以看到aAddon所有的属性。 http://smg.photobucket.com/user/noitidart/media/i20dont20see20nsIInterfaceRequestor_zps7bfc9d43.png.html?sort=3&o=12

http://smg.photobucket.com/user/noitidart/media/my20code20works_zpsdd244f45.png.html?sort=3&o=11