Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

There is a problem when accessing the embedFS on Windows build. #7

Closed
kbtxwer opened this issue Nov 21, 2023 · 2 comments
Closed

There is a problem when accessing the embedFS on Windows build. #7

kbtxwer opened this issue Nov 21, 2023 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@kbtxwer
Copy link

kbtxwer commented Nov 21, 2023

The console will show something like "open templetes/head.html file not exist" and which leads to the web ui failure.
I have solved the problem by adding

fname = strings.ReplaceAll(fname, "\\", "/")

which means change the Windows like separator into Unix like separator, before the filename sends to fs.Readfile()

However, maybe my solution is not so perfect and may cause other problems, could you please check if my solution always work nice or fix it with another way?

@kdudkov kdudkov self-assigned this Nov 23, 2023
@kdudkov
Copy link
Owner

kdudkov commented Nov 23, 2023

@kbtxwer, please check now

@kdudkov kdudkov added the bug Something isn't working label Nov 23, 2023
@kbtxwer
Copy link
Author

kbtxwer commented Nov 25, 2023

Thanks, I learned from it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants