Fixed wrong args.

d6
Frode Petterson 2014-12-15 11:50:48 +01:00
parent 2bba9a183b
commit acb36845c0
1 changed files with 2 additions and 3 deletions

View File

@ -112,14 +112,13 @@ H5P.EventDispatcher = (function () {
* @param {String} type Event type
* @param {...*} args
*/
self.trigger = function (type, args) {
self.trigger = function (type) {
if (events[type] === undefined) {
return;
}
// Copy all arguments except the first
args = [];
var i;
var i, args = [];
for (i = 1; i < arguments.length; i++) {
args.push(arguments[i]);
}