Guest User

Untitled

a guest
Dec 9th, 2018
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. function testFilename(filename) {
  2. const nomeProibido = 'nome'
  3. if (filename.includes(nomeProibido)) return false
  4. if (filename[0] === '2') return false
  5. return filename.match(/\.xls[xm]?$/)
  6. }
  7.  
  8. function appendTrueFalse(filename) {
  9. return `${filename} = ${testFilename(filename) ? 'true' : 'false'}`
  10. }
Add Comment
Please, Sign In to add comment