8000 Split dynamodb_table_supplier by sundowndev · Pull Request #820 · snyk/driftctl · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Split dynamodb_table_supplier #820

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its main 10000 tainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 8, 2021
Merged

Conversation

sundowndev
Copy link
Contributor

fixes #714

@sundowndev sundowndev requested a review from a team as a code owner July 8, 2021 14:00
@sundowndev sundowndev force-pushed the feat/dynamodb_table_deepmode branch from 203c2c9 to 20b103e Compare July 8, 2021 14:02
@codecov
Copy link
codecov bot commented Jul 8, 2021

Codecov Report

Merging #820 (cff7a2f) into main (97af9a4) will increase coverage by 0.09%.
The diff coverage is 82.35%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #820      +/-   ##
==========================================
+ Coverage   77.85%   77.95%   +0.09%     
==========================================
  Files         222      223       +1     
  Lines        6394     6400       +6     
==========================================
+ Hits         4978     4989      +11     
+ Misses       1179     1174       -5     
  Partials      237      237              
Impacted Files Coverage Δ
pkg/remote/aws/init.go 0.00% <0.00%> (ø)
pkg/remote/aws/dynamodb_table_details_fetcher.go 73.33% <73.33%> (ø)
pkg/remote/aws/dynamodb_table_enumerator.go 100.00% <100.00%> (ø)

lotoussa
lotoussa previously approved these changes Jul 8, 2021
results,
e.factory.CreateAbstractResource(
string(e.SupportedType()),
*table,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't we use aws.StringValue() ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I honestly don't know, according to other enumerators I think we do. Howether that means we could create a resource with empty string as ID 🤔

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what StringValue does:

func StringValue(v *string) string {
	if v != nil {
		return *v
	}
	return ""
}

It's nothing but a dereference here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, also if table is nil, it'll not crash but use "" as resource id, which sounds weird

@sundowndev sundowndev merged commit af253a1 into main Jul 8, 2021
@sundowndev sundowndev deleted the feat/dynamodb_table_deepmode branch July 8, 2021 15:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Split dynamodb_table_supplier
3 participants
0