73% pcmegaworks

Code Review | PCMegaworks

WordPress plugin PCMegaworks scored73%from 54 tests.

About plugin

  • Plugin page: pcmegaworks
  • Plugin version: 001.040.010
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5.4-5.5.3
  • WordPress version: 6.3.1
  • First release: Nov 27, 2016
  • Latest release: Nov 7, 2020
  • Number of updates: 38
  • Update frequency: every 37.9 days
  • Top authors: progressivecoding (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,110 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲2.60MB] [CPU: ▼1.97ms] Passed 4 tests

An overview of server-side resources used by PCMegaworks
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /6.76 ▲3.3068.65 ▲26.36
Dashboard /wp-admin6.60 ▲3.2564.33 ▼5.51
Posts /wp-admin/edit.php6.71 ▲3.3665.81 ▲13.74
Add New Post /wp-admin/post-new.php6.44 ▲0.5660.42 ▼42.45
Media Library /wp-admin/upload.php6.52 ▲3.29194.37 ▲156.30

Server storage [IO: ▲3.22MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
Please try to fix the following items
  • The plugin illegally modified 1 file (4.00KB) outside of "wp-content/plugins/pcmegaworks/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 119 new files
Database: no new tables, 8 new options
New WordPress options
widget_theysaidso_widget
PCPlugin_Activation
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
PCPlugin
db_upgraded

Browser metrics Passed 4 tests

PCMegaworks: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,127 ▲36616.20 ▲1.8214.93 ▲13.0655.28 ▲10.80
Dashboard /wp-admin2,370 ▲1676.84 ▲0.99108.55 ▼0.8180.75 ▲35.53
Posts /wp-admin/edit.php2,206 ▲1093.49 ▲1.4441.49 ▲4.2854.35 ▲15.81
Add New Post /wp-admin/post-new.php1,431 ▼11421.44 ▼1.70582.76 ▼75.4866.37 ▲17.59
Media Library /wp-admin/upload.php1,541 ▲1445.99 ▲1.78112.49 ▲16.4955.62 ▲10.77

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • The plugin did not uninstall gracefully
    • > Notice in wp-content/plugins/pcmegaworks/includes/PCMW_Config.php+659
    Undefined index: PCPLUGINACTIVE
  • The uninstall procedure has failed, leaving 8 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • PCPlugin
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • PCPlugin_Deactivation

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 10× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_BootQueryUpdater.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_ChatMessage.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_CSSInterface.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_MailBlast.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_CustomMenu.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_WatermarkCore.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_404Redirect.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_Login.php:10
    • > AH02429
      Response header name 'Location ' contains invalid characters, aborting request
    • > PHP Fatal error
      Uncaught Error: Class 'PCMW_BaseClass' not found in wp-content/plugins/pcmegaworks/includes/PCMW_PluginCoreHelper.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: broken images, mail blast, 404 redirects, custom forms, basic chat...

pcmegaworks/PCMegaworks.php 77% from 13 tests

The primary PHP file in "PCMegaworks" version 001.040.010 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("pcmegaworks.php" instead of "PCMegaworks.php")
  • Domain Path: The domain path follows the same naming rules as the domain name, using only dashes and lowercase characters ("/PCMegaworks")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected26,496 lines of code in 75 files:
LanguageFilesBlank linesComment linesLines of code
PHP561,5186,33515,652
CSS881687,738
JavaScript97185672,809
SVG100288
HTML1509

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity53.59
▷ Minimum class complexity1.00
▷ Maximum class complexity253.00
Average method complexity4.22
▷ Minimum method complexity1.00
▷ Maximum method complexity44.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes56
▷ Abstract classes00.00%
▷ Concrete classes56100.00%
▷ Final classes00.00%
Methods916
▷ Static methods899.72%
▷ Public methods90498.69%
▷ Protected methods80.87%
▷ Private methods40.44%
Functions17
▷ Named functions17100.00%
▷ Anonymous functions00.00%
Constants31
▷ Global constants2683.87%
▷ Class constants516.13%
▷ Public constants5100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
25 PNG files occupy 0.56MB with 0.21MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/46.png9.11KB4.31KB▼ 52.72%
assets/images/m4.png5.57KB4.23KB▼ 24.08%
assets/images/people35.png1.36KB1.43KB0.00%
assets/screenshot-3.png26.97KB12.88KB▼ 52.24%
assets/images/20.png9.01KB3.52KB▼ 60.90%