Commit f8d7dc15 authored by Julien Fontanet's avatar Julien Fontanet

fix(rmdir): dont test existence

Similar to 4b8f5754
parent fd95d450
......@@ -18,9 +18,6 @@ var BigInt = require('../tools/bigint');
module.exports = function unlink(path, cb) {
var connection = this;
connection.exists(path, function(err, exists) {
if (err) cb && cb(err);
else if (exists) {
// SMB2 open file
SMB2Request('create', { path: path }, connection, function(err, file) {
if (err) cb && cb(err);
......@@ -44,8 +41,4 @@ module.exports = function unlink(path, cb) {
}
);
});
} else {
cb(new Error('File does not exists'));
}
});
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment