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

feat: Use Last-Modified header to set the file mtime by default #589

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

radaiming
Copy link
Contributor

Copy link
Owner

@iawia002 iawia002 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

Copy link
Owner

@iawia002 iawia002 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(忽略上面的 approve

@@ -67,6 +67,12 @@ func writeFile(
if copyErr != nil && copyErr != io.EOF {
return written, fmt.Errorf("file copy error: %s", copyErr)
}
if !config.NoMTime {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个不应该写在这儿,一次下载这个可能会被调用很多次,放到 Save 里,等下载完成了再操作这个

@radaiming
Copy link
Contributor Author

我又改了一发,有空可以帮忙看一眼

@iawia002 iawia002 force-pushed the master branch 4 times, most recently from dccdfc5 to de872ac Compare May 29, 2020 12:56
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