mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 09:34:57 +08:00
Modify: disable association_autoupdate in model.File.UpdateSourceName
This commit is contained in:
@@ -196,7 +196,7 @@ func (file *File) UpdateSize(value uint64) error {
|
||||
|
||||
// UpdateSourceName 更新文件的源文件名
|
||||
func (file *File) UpdateSourceName(value string) error {
|
||||
return DB.Model(&file).Update("source_name", value).Error
|
||||
return DB.Model(&file).Set("gorm:association_autoupdate", false).Update("source_name", value).Error
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user