forked from TrueCloudLab/restic
Use local time for user-provided time of backup
This commit is contained in:
parent
4ab0022da8
commit
a7971a3ece
1 changed files with 1 additions and 1 deletions
|
@ -377,7 +377,7 @@ func runBackup(opts BackupOptions, gopts GlobalOptions, term *termstatus.Termina
|
|||
|
||||
timeStamp := time.Now()
|
||||
if opts.TimeStamp != "" {
|
||||
timeStamp, err = time.Parse(TimeFormat, opts.TimeStamp)
|
||||
timeStamp, err = time.ParseInLocation(TimeFormat, opts.TimeStamp, time.Local)
|
||||
if err != nil {
|
||||
return errors.Fatalf("error in time option: %v\n", err)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue