summaryrefslogtreecommitdiff
path: root/runtime/js
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/js')
-rw-r--r--runtime/js/30_fs.js10
1 files changed, 8 insertions, 2 deletions
diff --git a/runtime/js/30_fs.js b/runtime/js/30_fs.js
index 11e9b32ef..c9daddacb 100644
--- a/runtime/js/30_fs.js
+++ b/runtime/js/30_fs.js
@@ -156,11 +156,17 @@
}
function renameSync(oldpath, newpath) {
- core.opSync("op_rename_sync", { oldpath, newpath });
+ core.opSync("op_rename_sync", {
+ oldpath: pathFromURL(oldpath),
+ newpath: pathFromURL(newpath),
+ });
}
async function rename(oldpath, newpath) {
- await core.opAsync("op_rename_async", { oldpath, newpath });
+ await core.opAsync("op_rename_async", {
+ oldpath: pathFromURL(oldpath),
+ newpath: pathFromURL(newpath),
+ });
}
function parseFileInfo(response) {