Bind overridden methods to the plugin context

This commit is contained in:
JC Brand 2015-05-10 17:15:15 +02:00
parent 91638cabe1
commit 42437ffa91

View File

@ -5614,7 +5614,7 @@
if (typeof value === "function") {
plugin._super = {'converse': converse};
plugin._super[key] = converse[key].bind(converse);
converse[key] = value.bind(this);
converse[key] = value.bind(plugin);
} else {
converse[key] = value;
}