mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-11-01 16:13:00 +00:00
Minor refactoring
This commit is contained in:
@@ -58,11 +58,10 @@ FileRetriever.retrieveFile = function(filepath,contextPath,callback) {
|
|||||||
// If we've got a full HTTP URI then we're good to go
|
// If we've got a full HTTP URI then we're good to go
|
||||||
newpath = url.resolve(contextPath,filepath);
|
newpath = url.resolve(contextPath,filepath);
|
||||||
httpRequestQueue.push({url: newpath},callback);
|
httpRequestQueue.push({url: newpath},callback);
|
||||||
return newpath;
|
|
||||||
} else {
|
} else {
|
||||||
// It's a file requested in a file context
|
// It's a file requested in a file context
|
||||||
newpath = path.resolve(path.dirname(contextPath),filepath);
|
newpath = path.resolve(path.dirname(contextPath),filepath);
|
||||||
fileRequestQueue.push({filepath: newpath},callback);
|
fileRequestQueue.push({filepath: newpath},callback);
|
||||||
|
}
|
||||||
return newpath;
|
return newpath;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|||||||
Reference in New Issue
Block a user