Skip to content

Commit

Permalink
Fixes types for layoutId
Browse files Browse the repository at this point in the history
  • Loading branch information
Joel Griffith committed Mar 16, 2020
1 parent b002fd5 commit 9c2ecb7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ interface Props {
apiClient: ReportingAPIClient;
toasts: ToastsSetup;
reportType: string;
layoutId: string;
layoutId: string | undefined;
objectId?: string;
objectType: string;
getJobParams: () => any;
Expand Down Expand Up @@ -54,7 +54,7 @@ class ReportingPanelContentUi extends Component<Props, State> {
};

public componentDidUpdate(prevProps: Props, prevState: State) {
if (this.props.layoutId !== prevState.layoutId) {
if (this.props.layoutId && this.props.layoutId !== prevState.layoutId) {
this.setState({
...prevState,
absoluteUrl: this.getAbsoluteReportGenerationUrl(this.props),
Expand Down

0 comments on commit 9c2ecb7

Please sign in to comment.