mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 04:14:39 +03:00
Fix date fields not being nulled correctly when cleared (#3243)
* Interpret empty string date as null * Fix setSQLiteDate for null
This commit is contained in:
@@ -143,7 +143,7 @@ func (t changesetTranslator) optionalDate(value *string, field string) models.Op
|
||||
return models.OptionalDate{}
|
||||
}
|
||||
|
||||
if value == nil {
|
||||
if value == nil || *value == "" {
|
||||
return models.OptionalDate{
|
||||
Set: true,
|
||||
Null: true,
|
||||
|
||||
Reference in New Issue
Block a user