/*
* Function makes the correction of the verb tense if it is different from
* Present Perfect or Present Perfect Continuous
*
* for the rule Time-markers 3.1.1 id: 83a5553764eaf1fe80ece27a14efb7af
*/

/*
* Pour plus tard. Prendre en compte:
* - nombre de mots dans le predicat;
* - nombre de mots dans le sujet;
* - type de phrase (affirmatif/negatif/interrogatif)
*/

module.exports = function (ruleManager, sentence, result) {

    if (!ruleManager || !result || !result.tokenIndices || result.tokenRules.length < 4 || !sentence) {
        debugger;
        console.error("inputs are wrong");
        return false;
    }

    // number of words forming the subject
    let subjectLength = result.tokenRules[0].tokenIndices.length;

    if (!subjectLength) {
        debugger;
        return false;
    }

    let predicateLength = result.tokenRules[2].tokenIndices.length;

    if (!predicateLength) {
        debugger;
        return false;
    }

    return true;
}