Skip to content

Commit 310fb60

Browse files
committed
only search real uri in Windows
1 parent 5b5ffd7 commit 310fb60

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

script/files.lua

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@ end
7373
---@param uri uri
7474
---@return uri
7575
function m.getRealUri(uri)
76+
if platform.OS ~= 'Windows' then
77+
return uri
78+
end
7679
local filename = furi.decode(uri)
7780
-- normalize uri
7881
uri = furi.encode(filename)

script/filewatch.lua

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
local fw = require 'bee.filewatch'
22
local fs = require 'bee.filesystem'
3+
local plat = require 'bee.platform'
34
local await = require 'await'
45

56
local MODIFY = 1 << 0
@@ -11,6 +12,9 @@ local function isExists(filename)
1112
if not suc or not exists then
1213
return false
1314
end
15+
if plat.OS ~= 'Windows' then
16+
return true
17+
end
1418
local suc, res = pcall(fs.fullpath, path)
1519
if not suc then
1620
return false

0 commit comments

Comments
 (0)