Develop/script.js
// builds final Array that will be used in password generator
builds final Array that will be used in password generator
builds final Array that will be used in password generator
function finalCharArray(wantsLower, wantsUpper, wantsNum, wantsSpecialChars) {
  var passwordChars = [];
  if (wantsLower === true) {
    passwordChars = passwordChars.concat(lower)
  }
  if (wantsUpper === true) {
    passwordChars = passwordChars.concat(upper)
  }
  if (wantsNum === true) {
    passwordChars = passwordChars.concat(num)
  }
  if (wantsSpecialChars === true) {
    passwordChars = passwordChars.concat(specialChars)
  }
  return passwordChars;
}
function finalCharArray ( wantsLower , wantsUpper , wantsNum , wantsSpecialChars ) { var passwordChars = [ ] ; if ( wantsLower === true ) { passwordChars = passwordChars . concat ( lower ) } if ( wantsUpper === true ) { passwordChars = passwordChars . concat ( upper ) } if ( wantsNum === true ) { passwordChars = passwordChars . concat ( num ) } if ( wantsSpecialChars === true ) { passwordChars = passwordChars . concat ( specialChars ) } return passwordChars ; }
builds final Array that will be used in password generator
builds final Array that will be used in password generator