fix linter
Signed-off-by: Raffaele Di Fazio <raffo@github.com>
This commit is contained in:
parent
68f4cad1af
commit
5cd90fea88
2 changed files with 5 additions and 5 deletions
|
|
@ -521,7 +521,7 @@ func (a *API) FilterCodespacesToDelete(codespaces []*Codespace, keepThresholdDay
|
|||
// get a date from a string representation
|
||||
t, err := time.Parse(time.RFC3339, codespace.LastUsedAt)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("error parsing last used at date: %v", err)
|
||||
return nil, fmt.Errorf("error parsing last used at date: %w", err)
|
||||
}
|
||||
if t.Before(now().AddDate(0, 0, -keepThresholdDays)) && codespace.Environment.State == "Shutdown" {
|
||||
codespacesToDelete = append(codespacesToDelete, codespace)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue