Skip to content

Commit

Permalink
Merge pull request #45 from Clever/fix-timestamp
Browse files Browse the repository at this point in the history
Add LastModifiedDate to metadata
  • Loading branch information
ulziibay authored Jan 6, 2021
2 parents 4981911 + 027d2a3 commit 36e4eb9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions store/parameter_store.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ func (s *ParameterStore) Read(id SecretIdentifier) (Secret, error) {
}
}
resp = regionalOutput[Region]
return Secret{*resp.Parameter.Value, SecretMeta{Version: convertFromSSMVersion(int(*resp.Parameter.Version))}}, nil
return Secret{*resp.Parameter.Value, SecretMeta{Created: *resp.Parameter.LastModifiedDate, Version: convertFromSSMVersion(int(*resp.Parameter.Version))}}, nil
}

// ReadVersion reads a specific version of a secret from the store.
Expand All @@ -191,7 +191,7 @@ func (s *ParameterStore) ReadVersion(id SecretIdentifier, version int) (Secret,
}
}
resp = regionalOutput[Region]
return Secret{*resp.Parameter.Value, SecretMeta{Version: convertFromSSMVersion(int(*resp.Parameter.Version))}}, nil
return Secret{*resp.Parameter.Value, SecretMeta{Created: *resp.Parameter.LastModifiedDate, Version: convertFromSSMVersion(int(*resp.Parameter.Version))}}, nil
}

// Update updates a Secret from the store and increments version number.
Expand Down

0 comments on commit 36e4eb9

Please # to comment.