Closed benz9527 closed 1 year ago
what is the status of the response at the time when you execute modifiy reponse?
can you output that inside please
ctx.fasthttp.Response.StatusCode()
and i would suggest that you do not define the same thing twice for scss
what is the status of the response at the time when you execute modifiy reponse?
can you output that inside please
ctx.fasthttp.Response.StatusCode()
and i would suggest that you do not define the same thing twice for scss
Actually, I just try to request a no exists asset name search.abc
under the path /theme/scss
.
Why not use the filesystem middleware to handle this batch of files?
And I think you can check if there is a usage error, and if there is no solution, you are welcome to provide a github repo of the code snippet used to reproduce the problem to see what went wrong
为什么不使用filesystem中间件来处理这批文件呢?
并且我觉得你可以检查一下是否用法出现了错误, 如果实在没有办法解决, 欢迎你提供一个用于复现问题的代码片段的 github repo 用于查看是哪里出了问题
The problem has nothing to do with fasthttp.FS, it's just that I signed up for global error handling, but haven't started implementing the logic yet, so it permits all errors. I made a simple version of registerStatic that also solved the problem.
这个问题其实和 fasthttp.FS 没啥关系,主要是我之前注册了全局的错误处理,但是还没有开始实现具体的逻辑,导致它放行了所有的错误。我做了个猴版的 registerStatic 函数,也能解决问题。
Closed.
Question Description
I read the
registerStatic
fiber version: v2.42.0
I have checked the issues, and found an issue related with this code snippet (#1099), though this issue is not same as my question actually.
Code Snippet (optional)
Checklist: