XoopsModules25x/xoopsinfo

View on GitHub

Showing 613 of 16,781 total issues

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

                                } elseif (preg_match('/^\s+inet\saddr:(\S+)\s+P-t-P:(\S+)/i', $buf2, $ar_buf2)
                                       || preg_match('/^\s+inet\s+(\S+)\s+netmask.+destination\s+(\S+)/i', $buf2, $ar_buf2)
                                       || preg_match('/^\s+inet\s+([^\/\s]+).*peer\s+([^\/\s]+).*\s+scope\s((global)|(host))/i', $buf2, $ar_buf2)) {
                                    if ($ar_buf2[1] != $ar_buf2[2]) {
                                        $dev->setInfo(($dev->getInfo()?$dev->getInfo().';':'').$ar_buf2[1].";:".$ar_buf2[2]);
Severity: Major
Found in phpsysinfo/includes/os/class.Linux.inc.php and 2 other locations - About 55 mins to fix
phpsysinfo/includes/os/class.Linux.inc.php on lines 1108..1114
phpsysinfo/includes/os/class.Linux.inc.php on lines 1200..1207

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 99.

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 3 locations. Consider refactoring.
Open

                            } elseif (preg_match('/^\s+inet\saddr:(\S+)\s+P-t-P:(\S+)/i', $line, $ar_buf2)
                                  || preg_match('/^\s+inet\s+(\S+)\s+netmask.+destination\s+(\S+)/i', $line, $ar_buf2)) {
                                if ($ar_buf2[1] != $ar_buf2[2]) {
                                     $dev->setInfo(($dev->getInfo()?$dev->getInfo().';':'').$ar_buf2[1].";:".$ar_buf2[2]);
                                } else {
Severity: Major
Found in phpsysinfo/includes/os/class.Linux.inc.php and 2 other locations - About 55 mins to fix
phpsysinfo/includes/os/class.Linux.inc.php on lines 1019..1027
phpsysinfo/includes/os/class.Linux.inc.php on lines 1108..1114

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 99.

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 10 locations. Consider refactoring.
Open

    case "pb":
        show += round(bytes / Math.pow(1000, 5), 2);
        show += String.fromCharCode(160) + genlang(91);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "mib":
        show += round(bytes / Math.pow(1024, 2), 2);
        show += String.fromCharCode(160) + genlang(88);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "kib":
        show += round(bytes / Math.pow(1024, 1), 2);
        show += String.fromCharCode(160) + genlang(89);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "tb":
        show += round(bytes / Math.pow(1000, 4), 2);
        show += String.fromCharCode(160) + genlang(85);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "pib":
        show += round(bytes / Math.pow(1024, 5), 2);
        show += String.fromCharCode(160) + genlang(90);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "tib":
        show += round(bytes / Math.pow(1024, 4), 2);
        show += String.fromCharCode(160) + genlang(86);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "gib":
        show += round(bytes / Math.pow(1024, 3), 2);
        show += String.fromCharCode(160) + genlang(87);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "mb":
        show += round(bytes / Math.pow(1000, 2), 2);
        show += String.fromCharCode(160) + genlang(40);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 10 locations. Consider refactoring.
Open

    case "gb":
        show += round(bytes / Math.pow(1000, 3), 2);
        show += String.fromCharCode(160) + genlang(41);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1698..1701

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 53.

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 3 locations. Consider refactoring.
Open

            if ( oSettings.sTableId !== '' && typeof oSettings.aanFeatures.f == "undefined" )
            {
                nFilter.setAttribute( 'id', oSettings.sTableId+'_filter' );
            }
Severity: Major
Found in phpsysinfo/js/jQuery/jquery.dataTables.js and 2 other locations - About 55 mins to fix
phpsysinfo/js/jQuery/jquery.dataTables.js on lines 5290..5293
phpsysinfo/js/jQuery/jquery.dataTables.js on lines 5356..5359

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 53.

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 3 locations. Consider refactoring.
Open

            if ( oSettings.sTableId !== '' && typeof oSettings.aanFeatures.r == "undefined" )
            {
                nProcessing.setAttribute( 'id', oSettings.sTableId+'_processing' );
            }
Severity: Major
Found in phpsysinfo/js/jQuery/jquery.dataTables.js and 2 other locations - About 55 mins to fix
phpsysinfo/js/jQuery/jquery.dataTables.js on lines 4284..4287
phpsysinfo/js/jQuery/jquery.dataTables.js on lines 5290..5293

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 53.

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 10 locations. Consider refactoring.
Open

    case "kb":
        show += round(bytes / Math.pow(1000, 1), 2);
        show += String.fromCharCode(160) + genlang(39);
        break;
Severity: Major
Found in phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js and 9 other locations - About 55 mins to fix
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1662..1665
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1666..1669
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1670..1673
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1674..1677
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1678..1681
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1682..1685
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1686..1689
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1690..1693
phpsysinfo/js/phpSysInfo/phpsysinfo_bootstrap.js on lines 1694..1697

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 53.

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 3 locations. Consider refactoring.
Open

            if ( oSettings.sTableId !== '' && typeof oSettings.aanFeatures.l == "undefined" )
            {
                nLength.setAttribute( 'id', oSettings.sTableId+'_length' );
            }
Severity: Major
Found in phpsysinfo/js/jQuery/jquery.dataTables.js and 2 other locations - About 55 mins to fix
phpsysinfo/js/jQuery/jquery.dataTables.js on lines 4284..4287
phpsysinfo/js/jQuery/jquery.dataTables.js on lines 5356..5359

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 53.

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 4 locations. Consider refactoring.
Open

                                case 2:
                                    $this->_result['devices'][$devname]['action']['name'] = "reconstructing";
                                    if (isset($raid_virtual['virtualDiskProgress'])) {
                                        $this->_result['devices'][$devname]['action']['percent'] = $raid_virtual['virtualDiskProgress'];
                                    } else {
Severity: Major
Found in phpsysinfo/plugins/raid/class.raid.inc.php and 3 other locations - About 55 mins to fix
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1206..1213
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1214..1221
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1222..1229

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 98.

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 4 locations. Consider refactoring.
Open

                                case 3:
                                    $this->_result['devices'][$devname]['action']['name'] = "resyncing";
                                    if (isset($raid_virtual['virtualDiskProgress'])) {
                                        $this->_result['devices'][$devname]['action']['percent'] = $raid_virtual['virtualDiskProgress'];
                                    } else {
Severity: Major
Found in phpsysinfo/plugins/raid/class.raid.inc.php and 3 other locations - About 55 mins to fix
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1198..1205
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1214..1221
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1222..1229

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 98.

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 5 locations. Consider refactoring.
Open

            if ((trim($line) !== "") && (strpos($line, ':') === false)) {
                $sname = trim($line);
                if (preg_match('/^([^-]+)-/', $sname, $snamebuf)) {
                    $sname = ' ('.$snamebuf[1].')';
                } else {
Severity: Major
Found in phpsysinfo/includes/mb/class.lmsensors.inc.php and 4 other locations - About 55 mins to fix
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 159..166
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 210..217
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 263..270
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 323..330

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 98.

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 5 locations. Consider refactoring.
Open

            if ((trim($line) !== "") && (strpos($line, ':') === false)) {
                $sname = trim($line);
                if (preg_match('/^([^-]+)-/', $sname, $snamebuf)) {
                    $sname = ' ('.$snamebuf[1].')';
                } else {
Severity: Major
Found in phpsysinfo/includes/mb/class.lmsensors.inc.php and 4 other locations - About 55 mins to fix
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 159..166
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 210..217
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 263..270
phpsysinfo/includes/mb/class.lmsensors.inc.php on lines 375..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 98.

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 4 locations. Consider refactoring.
Open

                                case 1:
                                    $this->_result['devices'][$devname]['status'] = "unknown";
                                    $this->_result['devices'][$devname]['items'][0]['status']="W";
                                    $this->_result['devices'][$devname]['items'][0]['info'] = $this->_result['devices'][$devname]['status'];
                                    break;
Severity: Major
Found in phpsysinfo/plugins/raid/class.raid.inc.php and 3 other locations - About 55 mins to fix
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1176..1180
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1181..1185
phpsysinfo/plugins/raid/class.raid.inc.php on lines 1186..1190

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 98.

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