Skip to content

Commit 3a85eac

Browse files
committed
fs: undeprecate exists() and existsSync()
fs.exists() and fs.existsSync() were deprecated in #103. This commit removes the deprecation message, in order to stay more in sync with joyent/node for the io.js 1.0.0 release. Fixes: #257 PR-URL: #307 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Bert Belder <[email protected]>
1 parent 14dc917 commit 3a85eac

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/fs.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -217,25 +217,25 @@ fs.accessSync = function(path, mode) {
217217
binding.access(pathModule._makeLong(path), mode);
218218
};
219219

220-
fs.exists = util.deprecate(function(path, callback) {
220+
fs.exists = function(path, callback) {
221221
if (!nullCheck(path, cb)) return;
222222
var req = new FSReqWrap();
223223
req.oncomplete = cb;
224224
binding.stat(pathModule._makeLong(path), req);
225225
function cb(err, stats) {
226226
if (callback) callback(err ? false : true);
227227
}
228-
}, 'fs.exists() is deprecated. Use fs.access() instead.');
228+
};
229229

230-
fs.existsSync = util.deprecate(function(path) {
230+
fs.existsSync = function(path) {
231231
try {
232232
nullCheck(path);
233233
binding.stat(pathModule._makeLong(path));
234234
return true;
235235
} catch (e) {
236236
return false;
237237
}
238-
}, 'fs.existsSync() is deprecated. Use fs.accessSync() instead.');
238+
};
239239

240240
fs.readFile = function(path, options, callback_) {
241241
var callback = maybeCallback(arguments[arguments.length - 1]);

0 commit comments

Comments
 (0)