You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mohemmionic5/Mohem/node_modules_/null-check
ashwaq 66795daf5e add missing files 6 years ago
..
index.js add missing files 6 years ago
license add missing files 6 years ago
readme.md add missing files 6 years ago

readme.md

null-check Build Status

Ensure a path doesn't contain null bytes

The same check as done in all the core fs methods.

Install

$ npm install --save null-check

Usage

var nullCheck = require('null-check');

nullCheck('unicorn.png\u0000', function (err) {
	console.log(err);
	//=> { [Error: Path must be a string without null bytes.] code: 'ENOENT' }
});
//=> false

// the method is sync without a callback
nullCheck('unicorn.png');
//=> true

License

MIT © Sindre Sorhus