Bug 1141505 - avoid array.includes in xpcshell test. r=adw

This commit is contained in:
Mark Hammond 2015-03-11 09:27:07 +11:00
parent 811eacd3c4
commit ba65ed56c1

View File

@ -30,7 +30,7 @@ function createScheduler(options) {
// avoid typos in the test and other footguns in the options.
let allowedOptions = ["expectedDelay", "expectNewTimer", "syncFunction"];
for (let key of Object.keys(options)) {
if (!allowedOptions.includes(key)) {
if (allowedOptions.indexOf(key) == -1) {
throw new Error("Invalid option " + key);
}
}