Fix type error
This commit is contained in:
parent
a43d2df082
commit
3258aaa5d3
|
|
@ -41,10 +41,12 @@ const scrollLearnPathDiagram = (offset: number) => {
|
|||
|
||||
const filterCircles = (topic: TopicType) => {
|
||||
// return [];
|
||||
if (props.filter) {
|
||||
return topic.circles.filter((circle) => circle.profiles.indexOf(props.filter) > -1);
|
||||
if (props.filter === undefined) {
|
||||
return topic.circles;
|
||||
}
|
||||
return topic.circles;
|
||||
return topic.circles.filter(
|
||||
(circle) => circle.profiles.indexOf(props.filter as string) > -1
|
||||
);
|
||||
};
|
||||
</script>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue