mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-28 18:23:35 +00:00
feature(cloudcmd) fs: add realpath
This commit is contained in:
parent
c8a4817e1d
commit
188989a412
2 changed files with 18 additions and 8 deletions
|
|
@ -161,8 +161,13 @@
|
|||
};
|
||||
|
||||
if (isFile) {
|
||||
params.gzip = false;
|
||||
ponse.sendFile(params);
|
||||
fs.realpath(path, function(error, path) {
|
||||
if (!error)
|
||||
params.name = path;
|
||||
|
||||
params.gzip = false;
|
||||
ponse.sendFile(params);
|
||||
});
|
||||
} else {
|
||||
if (!error) {
|
||||
data.path = format.addSlashToEnd(p.name);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue