Skip to content
Browse files

add on / off to .bools

  • Loading branch information...
1 parent 105d6ef commit 4458f1c96ea11c9d20904e2c3a4604c7aa84e490 @tj tj committed Jul 19, 2012
Showing with 4 additions and 2 deletions.
  1. +1 −1 Readme.md
  2. +3 −1 lib/plugins/bools.js
View
2 Readme.md
@@ -107,7 +107,7 @@ yields:
### eson.bools
- Convert "yes", "no", "enabled", "disabled" into booleans.
+ Convert "yes", "no", "on", "off", "enabled", "disabled" into booleans.
### eson.env([prefix])
View
4 lib/plugins/bools.js
@@ -1,15 +1,17 @@
/**
- * Convert "yes", "no", "enabled", "disabled" to booleans.
+ * Convert "yes", "no", "on", "off", "enabled", "disabled" to booleans.
*/
module.exports = function(key, val){
switch (val) {
+ case 'on':
case 'yes':
case 'enable':
case 'enabled':
return true;
case 'no':
+ case 'off':
case 'disable':
case 'disabled':
return false;

0 comments on commit 4458f1c

Please sign in to comment.
Something went wrong with that request. Please try again.