AAfghahi commented on a change in pull request #17987:
URL: https://github.com/apache/superset/pull/17987#discussion_r782248631
##########
File path:
superset-frontend/src/SqlLab/components/ExploreResultsButton/index.jsx
##########
@@ -40,16 +40,8 @@ const defaultProps = {
query: {},
};
-class ExploreResultsButton extends React.PureComponent {
- constructor(props) {
- super(props);
- this.getInvalidColumns = this.getInvalidColumns.bind(this);
- this.renderInvalidColumnMessage =
- this.renderInvalidColumnMessage.bind(this);
- }
-
- getColumns() {
- const { props } = this;
+function ExploreResultsButton(props) {
Review comment:
All the others I completely agree with, but I think that this, being the
functional component itself, does not need to be an arrow function.
However, I think that you need to destructure props here, you can do that by
console logging the props and writing them out individually, its more explicit.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]