Created
May 18, 2019 21:01
-
-
Save powerc9000/770188ced50e85768f4b5cdefa6dd764 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isEnabled(flagName){ | |
const flag = flags.find((flag)=>{ | |
return flag.name === flagName | |
}) | |
//If the flag doesnt exist it sure isn't enabled | |
if(!flag){ | |
return false | |
} | |
return flag.enabled; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment