Skip to content
Snippets Groups Projects
Commit 6bbee58d authored by Alexander Rose's avatar Alexander Rose
Browse files

guard against undefined `values` in ParameterControls

parent 989faed4
No related branches found
No related tags found
No related merge requests found
...@@ -34,7 +34,7 @@ export class ParameterControls<P extends PD.Params> extends React.PureComponent< ...@@ -34,7 +34,7 @@ export class ParameterControls<P extends PD.Params> extends React.PureComponent<
const params = this.props.params; const params = this.props.params;
const values = this.props.values; const values = this.props.values;
const keys = Object.keys(params); const keys = Object.keys(params);
if (keys.length === 0) return null; if (keys.length === 0 || values === undefined) return null;
return <> return <>
{keys.map(key => { {keys.map(key => {
const param = params[key]; const param = params[key];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment