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

fix(ilanzou): fix upload failure for small files #7368

Merged
merged 1 commit into from
Oct 20, 2024

Conversation

Jason-Fly
Copy link
Contributor

修复问题: #7250

问题原因: 在通过/7n/getUpToken接口获取token时,如果请求传参中的文件KBfileSize字段为0,则会报错;而对于上传小于1024 Byte的文件时,目前是按1024整除得到的结果,也就是0,导致无法获取到token,从而中断了上传流程。

修复方案: 调研了蓝奏云优享版的/7n/getUpToken接口,发现他们在将字节数转为KB数时是向上取整的,所以改成向上取整应该可以解决,避免了计算结果为0的情况。

@xhofe xhofe merged commit a2dc45a into AlistGo:main Oct 20, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants