diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/bzpage.js | 6 | ||||
-rw-r--r-- | lib/mozillabzpage.js | 1 |
2 files changed, 5 insertions, 2 deletions
diff --git a/lib/bzpage.js b/lib/bzpage.js index ff616ea..e5797fd 100644 --- a/lib/bzpage.js +++ b/lib/bzpage.js @@ -346,11 +346,13 @@ BZPage.prototype.addToCommentsDropdown = function addToCommentsDropdown (pkg, cm " <option value=''>-- Select Comment from List --</option>" + "</div>"; select = this.doc.getElementById("comment_action"); - select.addEventListener("change", function () { + select.addEventListener("change", function (evt) { var value = ""; var valueElement = that.doc.getElementById("comment_action"); if (valueElement) { - value = valueElement.getAttribute("value"); + var selIdx = valueElement.selectedIndex; + value = valueElement.options[selIdx].value; + console.log("value = " + value); } else { return; } diff --git a/lib/mozillabzpage.js b/lib/mozillabzpage.js index 69e2926..31f6332 100644 --- a/lib/mozillabzpage.js +++ b/lib/mozillabzpage.js @@ -3,6 +3,7 @@ "use strict"; var utilMod = require("util"); var apiUtils = require("api-utils"); +var BZPage = require("bzpage").BZPage; // ============================================================================ // MozillaBugzilla object |