-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers 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
cluster-ui: delete unused vars #107798
cluster-ui: delete unused vars #107798
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really nice cleanup!
Reviewed 32 of 33 files at r1, all commit messages.
Reviewable status: complete! 0 of 0 LGTMs obtained (waiting on @xinhaoz)
pkg/ui/workspaces/cluster-ui/src/columnsSelector/columnsSelector.tsx
line 85 at r1 (raw file):
boxShadow: "none", }), menuList: (provided: any) => ({
this is required, is setting the values on the customStyles, which is called on the code below
Previously, maryliag (Marylia Gutierrez) wrote…
Ah, gotcha + nice catch! This shouldn't affect the eslint rule anyways since it's a property. I'll put it back 👍 |
Previously, xinhaoz (Xin Hao Zhang) wrote…
Done. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: complete! 0 of 0 LGTMs obtained (waiting on @xinhaoz)
pkg/ui/workspaces/cluster-ui/src/api/databaseDetailsApi.ts
line 96 at r2 (raw file):
} }, handleMaxSizeError: () => {
I'm surprise this is not giving errors after you removed the values. On the DatabaseDetailsQuery
type this function is defined as receiving these 3 parameters, but you removed from almost all implementations. Can you confirm this is really handling correctly the max size error?
Previously, maryliag (Marylia Gutierrez) wrote…
I think it's because in JS/TS when a function is called with more arguments than there are params, theyre just ignored. One query that has |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r2, 1 of 1 files at r3, all commit messages.
Reviewable status: complete! 1 of 0 LGTMs obtained (waiting on @xinhaoz)
pkg/ui/workspaces/cluster-ui/src/api/databaseDetailsApi.ts
line 96 at r2 (raw file):
Previously, xinhaoz (Xin Hao Zhang) wrote…
I think it's because in JS/TS when a function is called with more arguments than there are params, theyre just ignored. One query that has
handleMaxSizeError
functions does use those params which is why theyre still included there. For consistency, instead of creating a union type to include functions without params, I've just appended the unused params with_
so we can continue to use the single type without confusion.
Thanks!
Delete unused vars in cluster-ui. A following commit will turn unused vars to errors via the eslint config. Release note: None Epic: none
TFTR! |
Build succeeded: |
Delete unused vars in cluster-ui. A following commit will turn unused vars to errors via the eslint config.
Epic: None
Release note: None