We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 735aadc commit 9a0c65eCopy full SHA for 9a0c65e
1 file changed
src/components/portfolioPage/Corpora.jsx
@@ -14,12 +14,11 @@ class Corpora extends Component {
14
};
15
16
sort = memoize((items, criteria) => items.sort(by(`${criteria}.0`)));
17
-
18
componentWillReceiveProps(props) {
19
this.setState({
20
- listCorpus: props.ids
21
- })
22
-}
+ listCorpus: [ ...props.ids ]
+ });
+ }
23
render() {
24
let itemsData = this.sort(this.props.items, this.state.criteria);
25
let items = itemsData.map(x =>
@@ -86,7 +85,7 @@ class Corpora extends Component {
86
85
87
isChecked(corpus) {
88
let list = this.state.listCorpus;
89
- if (!list.includes(corpus)) {
+ if (list.includes(corpus)) {
90
return true;
91
}
92
return false;
0 commit comments