Grammalecte  Diff

Differences From Artifact [9717be7ff0]:

To Artifact [5369fe7f34]:


191
192
193
194
195
196
197





198
199
200
201
202
203
204
205
206
    _checkSuggestions (sAllExceptedSuggs, sAllFoundSuggs) {
        let lAllExpectedSuggs = sAllExceptedSuggs.split("|||");
        let lAllFoundSuggs = sAllFoundSuggs.split("|||");
        if (lAllExpectedSuggs.length != lAllFoundSuggs.length) {
            return false;
        }
        for (let i = 0;  i < lAllExpectedSuggs.length;  i++) {





            let aExpectedSuggs = new Set(lAllExpectedSuggs[i].split("|"));
            let aFoundSuggs = new Set(lAllFoundSuggs[i].split("|"));
            if (aExpectedSuggs.size !== aFoundSuggs.size || ![...aExpectedSuggs].every(value => aFoundSuggs.has(value))) {
                return false;
            }
        }
        return true;
    }
}







>
>
>
>
>
|
|







191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
    _checkSuggestions (sAllExceptedSuggs, sAllFoundSuggs) {
        let lAllExpectedSuggs = sAllExceptedSuggs.split("|||");
        let lAllFoundSuggs = sAllFoundSuggs.split("|||");
        if (lAllExpectedSuggs.length != lAllFoundSuggs.length) {
            return false;
        }
        for (let i = 0;  i < lAllExpectedSuggs.length;  i++) {
            let lExpectedSuggs = lAllExpectedSuggs[i].split("|");
            let lFoundSuggs = lAllFoundSuggs[i].split("|");
            if (lExpectedSuggs.length != lFoundSuggs.length) {
                return false;
            }
            let aExpectedSuggs = new Set(lExpectedSuggs);
            let aFoundSuggs = new Set(lFoundSuggs);
            if (aExpectedSuggs.size !== aFoundSuggs.size || ![...aExpectedSuggs].every(value => aFoundSuggs.has(value))) {
                return false;
            }
        }
        return true;
    }
}