78% syntaxhighlighter-to-pastacode

Code Review | SyntaxHighlighter Evolved to Pastacode

WordPress plugin SyntaxHighlighter Evolved to Pastacode scored 78% from 54 tests.

About plugin

  • Plugin page: syntaxhighlighter...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-4.6
  • WordPress version: 6.3.1
  • First release: Sep 1, 2016
  • Latest release: Sep 1, 2016
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: willybahuaud (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 542 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼1.40ms] Passed 4 tests

A check of server-side resources used by SyntaxHighlighter Evolved to Pastacode
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0142.95 ▲3.47
Dashboard /wp-admin3.32 ▲0.0153.36 ▼1.09
Posts /wp-admin/edit.php3.37 ▲0.0145.86 ▼0.93
Add New Post /wp-admin/post-new.php5.92 ▲0.0384.20 ▼1.72
Media Library /wp-admin/upload.php3.24 ▲0.0135.76 ▼1.86
Migrate to Pastacode /wp-admin/tools.php?page=migrate_s2p3.1828.88

Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for SyntaxHighlighter Evolved to Pastacode
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲2913.30 ▲0.134.58 ▲2.7544.37 ▼2.32
Dashboard /wp-admin2,210 ▲184.88 ▼1.04112.07 ▼3.4646.54 ▼0.56
Posts /wp-admin/edit.php2,093 ▲42.09 ▲0.1137.41 ▼0.3033.66 ▼1.75
Add New Post /wp-admin/post-new.php1,517 ▲317.50 ▲0.05696.42 ▲44.3750.84 ▲1.21
Media Library /wp-admin/upload.php1,389 ▲14.19 ▲0.0097.13 ▼17.4841.68 ▼7.77
Migrate to Pastacode /wp-admin/tools.php?page=migrate_s2p7732.0326.1826.23

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/tools.php?page=migrate_s2p
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/tools.php?page=migrate_s2p
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/tools.php?page=migrate_s2p
    • > User notice in wp-includes/functions.php+5905
    Function WP_Scripts::localize was called incorrectly. The $l10n parameter must be an array. To pass arbitrary data to scripts, use the wp_add_inline_script() function instead. Please see Debugging in WordPress for more information. (This message was added in version 5.7.0.)

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Wabeo\\S2p\\add_action() in wp-content/plugins/syntaxhighlighter-to-pastacode/syntaxhighlighter-to-pastacode.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: migration, evolved, convert, syntax, pastacode...

syntaxhighlighter-to-pastacode/syntaxhighlighter-to-pastacode.php 92% from 13 tests

The main PHP file in "SyntaxHighlighter Evolved to Pastacode" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin324 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP22928238
PO File1161651
JavaScript15035

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin