From f3a29b87e1658e7b7768ecf282366b2b3e1f9ce8 Mon Sep 17 00:00:00 2001 From: Shawn Date: Mon, 19 Oct 2015 15:34:44 -0700 Subject: [PATCH] Fixes and issue where If args are not present script terminates --- src/js/select2/core.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/js/select2/core.js b/src/js/select2/core.js index be866a19..af48de5e 100644 --- a/src/js/select2/core.js +++ b/src/js/select2/core.js @@ -357,6 +357,10 @@ define([ 'select': 'selecting', 'unselect': 'unselecting' }; + + if (args === undefined) { + args = {}; + } if (name in preTriggerMap) { var preTriggerName = preTriggerMap[name];