umask.js 343 B

1234567891011121314151617
  1. var umask = require('umask')
  2. var npmlog = require('npmlog')
  3. var _fromString = umask.fromString
  4. module.exports = umask
  5. // fromString with logging callback
  6. umask.fromString = function (val) {
  7. _fromString(val, function (err, result) {
  8. if (err) {
  9. npmlog.warn('invalid umask', err.message)
  10. }
  11. val = result
  12. })
  13. return val
  14. }