mambax7/smartfaq

View on GitHub

Showing 275 of 649 total issues

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function ol_content_background(text, picture, hasfullhtml) {
    if (hasfullhtml) {
        txt = text;
    } else {
        txt = '<table width="' + o3_width + '" border="0" cellpadding="0" cellspacing="0" height="' + o3_height + '"><tr><td colspan="3" height="' + o3_padyt + '"></td></tr><tr><td width="' + o3_padxl + '"></td><td valign="TOP" width="' + (o3_width - o3_padxl - o3_padxr) + (o3_textfontclass ? '" class="' + o3_textfontclass : '') + '">' + (o3_textfontclass ? '' : wrapStr(0, o3_textsize, 'text')) + text + (o3_textfontclass ? '' : wrapStr(1, o3_textsize)) + '</td><td width="' + o3_padxr + '"></td></tr><tr><td colspan="3" height="' + o3_padyb + '"></td></tr></table>';
Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 6 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 374..382

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 156.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function ol_content_background(text, picture, hasfullhtml) {
    if (hasfullhtml) {
        txt = text;
    } else {
        txt = '<table width="' + o3_width + '" border="0" cellpadding="0" cellspacing="0" height="' + o3_height + '"><tr><td colspan="3" height="' + o3_padyt + '"></td></tr><tr><td width="' + o3_padxl + '"></td><td valign="TOP" width="' + (o3_width - o3_padxl - o3_padxr) + (o3_textfontclass ? '" class="' + o3_textfontclass : '') + '">' + (o3_textfontclass ? '' : wrapStr(0, o3_textsize, 'text')) + text + (o3_textfontclass ? '' : wrapStr(1, o3_textsize)) + '</td><td width="' + o3_padxr + '"></td></tr><tr><td colspan="3" height="' + o3_padyb + '"></td></tr></table>';
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 6 hrs to fix
assets/js/overlib/overlib.js on lines 500..509

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 156.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function Info(version, prerelease) {
    this.version = version;
    this.prerelease = prerelease;
    this.simpleversion = Math.round(this.version * 100);
    this.major = parseInt(this.simpleversion / 100);
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib.js on lines 1528..1536

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 154.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function opt_NOCLOSE(unused) {
    if (!unused) o3_close = "";
    if (olNs4) {
        over.captureEvents(Event.MOUSEOUT || Event.MOUSEOVER);
        over.onmouseover = function () {
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib.js on lines 1130..1153

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 154.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function Info(version, prerelease) {
    this.version = version;
    this.prerelease = prerelease;

    this.simpleversion = Math.round(this.version * 100);
Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 1172..1179

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 154.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function opt_NOCLOSE(unused) {
    if (!unused) o3_close = "";

    if (olNs4) {
        over.captureEvents(Event.MOUSEOUT || Event.MOUSEOVER);
Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 884..905

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 154.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function ol_content_simple_cssstyle(text) {
    txt = '<table width="' + o3_width + '" border="0" cellpadding="' + o3_border + '" cellspacing="0" style="background-color: ' + o3_bgcolor + '; height: ' + o3_height + o3_heightunit + ';"><tr><td><table width="100%" border="0" cellpadding="' + o3_cellpad + '" cellspacing="0" style="color: ' + o3_fgcolor + '; background-color: ' + o3_fgcolor + '; height: ' + o3_height + o3_heightunit + ';"><tr><td valign="TOP"><font style="font-family: ' + o3_textfont + '; color: ' + o3_textcolor + '; font-size: ' + o3_textsize + o3_textsizeunit + '; text-decoration: ' + o3_textdecoration + '; font-weight: ' + o3_textweight + '; font-style:' + o3_textstyle + '">' + text + '</font></td></tr></table></td></tr></table>';
    set_background("");

    return txt;
Severity: Major
Found in assets/js/overlib/overlib_cssstyle.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_cssstyle_mini.js on lines 129..133

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 153.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function ol_content_simple_cssstyle(text) {
    txt = '<table width="' + o3_width + '" border="0" cellpadding="' + o3_border + '" cellspacing="0" style="background-color: ' + o3_bgcolor + '; height: ' + o3_height + o3_heightunit + ';"><tr><td><table width="100%" border="0" cellpadding="' + o3_cellpad + '" cellspacing="0" style="color: ' + o3_fgcolor + '; background-color: ' + o3_fgcolor + '; height: ' + o3_height + o3_heightunit + ';"><tr><td valign="TOP"><font style="font-family: ' + o3_textfont + '; color: ' + o3_textcolor + '; font-size: ' + o3_textsize + o3_textsizeunit + '; text-decoration: ' + o3_textdecoration + '; font-weight: ' + o3_textweight + '; font-style:' + o3_textstyle + '">' + text + '</font></td></tr></table></td></tr></table>';
    set_background("");
    return txt;
}
Severity: Major
Found in assets/js/overlib/mini/overlib_cssstyle_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib_cssstyle.js on lines 171..176

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 153.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function quoteMultiNameFonts(theFont) {
    var v, pM = theFont.split(',');
    for (var i = 0; i < pM.length; i++) {
        v = pM[i];
        v = v.replace(/^\s+/, '').replace(/\s+$/, '');
Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 961..972

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 150.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

function quoteMultiNameFonts(theFont) {
    var v, pM = theFont.split(',');
    for (var i = 0; i < pM.length; i++) {
        v = pM[i];
        v = v.replace(/^\s+/, '').replace(/\s+$/, '');
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib.js on lines 1233..1244

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 150.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function cursorOff() {
    var left = parseInt(over.style.left);
    var top = parseInt(over.style.top);
    var right = left + (over.offsetWidth >= parseInt(o3_width) ? over.offsetWidth : parseInt(o3_width));
    var bottom = top + (over.offsetHeight >= o3_aboveheight ? over.offsetHeight : o3_aboveheight);
Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 872..879

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 146.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function cursorOff() {
    var left = parseInt(over.style.left);
    var top = parseInt(over.style.top);
    var right = left + (over.offsetWidth >= parseInt(o3_width) ? over.offsetWidth : parseInt(o3_width));
    var bottom = top + (over.offsetHeight >= o3_aboveheight ? over.offsetHeight : o3_aboveheight);
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib.js on lines 1106..1115

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 146.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        if (($criteria instanceof \CriteriaCompo) || ($criteria instanceof \Criteria)) {
            $whereClause = $criteria->renderWhere();

            if ('WHERE ()' !== $whereClause) {
                $sql .= ' ' . $criteria->renderWhere();
Severity: Major
Found in class/FaqHandler.php and 1 other location - About 5 hrs to fix
class/FaqHandler.php on lines 252..270

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 191.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        if (($criteria instanceof \CriteriaCompo) || ($criteria instanceof \Criteria)) {
            $whereClause = $criteria->renderWhere();

            if ('WHERE ()' !== $whereClause) {
                $sql .= ' ' . $criteria->renderWhere();
Severity: Major
Found in class/FaqHandler.php and 1 other location - About 5 hrs to fix
class/FaqHandler.php on lines 333..351

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 191.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function generatePopUp(content) {
    if (!olIe4 || olOp || !olIe55 || (typeof o3_shadow != 'undefined' && o3_shadow) || (typeof o3_bubble != 'undefined' && o3_bubble)) return;
    var wd, ht, txt, zIdx = 0;
    wd = parseInt(o3_width);
    ht = over.offsetHeight;
Severity: Major
Found in assets/js/overlib/mini/overlib_hideform_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib_hideform.js on lines 18..28

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 140.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function generatePopUp(content) {
    if (!olIe4 || olOp || !olIe55 || (typeof o3_shadow != 'undefined' && o3_shadow) || (typeof o3_bubble != 'undefined' && o3_bubble)) return;

    var wd, ht, txt, zIdx = 0;

Severity: Major
Found in assets/js/overlib/overlib_hideform.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_hideform_mini.js on lines 14..22

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 140.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function nd(time) {
    if (olLoaded && !isExclusive()) {
        if (time && !o3_delay) {
            if (o3_timerid > 0) clearTimeout(o3_timerid);

Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 280..298

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 138.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

function nd(time) {
    if (olLoaded && !isExclusive()) {
        if (time && !o3_delay) {
            if (o3_timerid > 0) clearTimeout(o3_timerid);
            o3_timerid = setTimeout("cClick()", (o3_timeout = time));
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib.js on lines 348..369

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 138.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

            if (ar[i] == FUNCTION) {
                if (pf == 'ol_') {
                    if (typeof ar[i + 1] != 'number') {
                        v = ar[++i];
                        ol_function = (typeof v == 'function' ? v : null);
Severity: Major
Found in assets/js/overlib/overlib.js and 1 other location - About 5 hrs to fix
assets/js/overlib/mini/overlib_mini.js on lines 732..745

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 136.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

            if (ar[i] == FUNCTION) {
                if (pf == 'ol_') {
                    if (typeof ar[i + 1] != 'number') {
                        v = ar[++i];
                        ol_function = (typeof v == 'function' ? v : null);
Severity: Major
Found in assets/js/overlib/mini/overlib_mini.js and 1 other location - About 5 hrs to fix
assets/js/overlib/overlib.js on lines 939..952

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 136.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language