Skip to content

Commit

Permalink
Add support for non-multiple <select>
Browse files Browse the repository at this point in the history
  • Loading branch information
fregante committed Jun 7, 2017
1 parent f98bd11 commit 413b277
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions webext-options-sync.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@ class OptSync {
const name = el.name;
let value = el.value;
switch (el.type) {
case 'select-one':
value = el.options[el.selectedIndex].value;
break;
case 'checkbox':
value = el.checked;
break;
Expand Down

0 comments on commit 413b277

Please sign in to comment.