67% because

Code Review | Conva Comment System (Beta)

WordPress plugin Conva Comment System (Beta) scored 67% from 54 tests.

About plugin

  • Plugin page: because
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-4.0
  • WordPress version: 6.3.1
  • First release: May 12, 2014
  • Latest release: May 16, 2015
  • Number of updates: 141
  • Update frequency: every 2.6 days
  • Top authors: tjsantilo (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

10+ active / 3,792 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.19MB] [CPU: ▼4.47ms] Passed 4 tests

Server-side resources used by Conva Comment System (Beta)
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.2439.71 ▼5.17
Dashboard /wp-admin3.68 ▲0.3855.79 ▲6.73
Posts /wp-admin/edit.php3.74 ▲0.3853.73 ▲1.72
Add New Post /wp-admin/post-new.php5.75 ▼0.1482.14 ▼13.85
Media Library /wp-admin/upload.php3.53 ▲0.2935.09 ▼0.56
Social Polling /wp-admin/options-general.php?page=social-polling3.5336.51

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

Filesystem and database footprint
These are issues you should consider
  • Illegal file modification found: 1 file (0.00KB) outside of "wp-content/plugins/because/" and "wp-content/uploads/"
    • (new file) "wp-content/plugins/because/assets/banner-772\303\227250.jpg"
Filesystem: 60 new files
Database: 2 new tables, 7 new options
New tables
wp_social_polling_comments
wp_social_polling
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
db_upgraded
sp_db_version
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Conva Comment System (Beta)
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,060 ▲32515.28 ▲0.906.94 ▲5.0135.89 ▼13.04
Dashboard /wp-admin2,352 ▲1676.46 ▲0.64137.59 ▲28.3241.48 ▼3.48
Posts /wp-admin/edit.php2,258 ▲1693.36 ▲1.3149.35 ▲8.2832.60 ▼4.08
Add New Post /wp-admin/post-new.php6,573 ▲5,03720.09 ▼3.12874.86 ▲227.4339.11 ▼12.94
Media Library /wp-admin/upload.php1,400 ▲154.14 ▼0.0787.41 ▼14.4443.22 ▲1.18
Social Polling /wp-admin/options-general.php?page=social-polling1,0053.2940.6426.00

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_social_polling
    • wp_social_polling_comments
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-posts
    • sp_db_version
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/because/public/views/public.php
    • > /wp-content/plugins/because/admin/includes/download.php
  • 4× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/because/public/includes/class-sp_comments.php:21
    • > PHP Fatal error
      Uncaught Error: Call to undefined function post_password_required() in wp-content/plugins/because/public/includes/templates/sp_comments.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/because/admin/includes/voting_box.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/because/admin/views/admin.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need to be fixed:
  • Tags: Too many tags (13 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Donate link: Please fix this invalid URI: ""
Please take inspiration from this readme.txt

because/social-polling.php 85% from 13 tests

Analyzing the main PHP file in "Conva Comment System (Beta)" version 1.6
The following require your attention:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("because.php" instead of "social-polling.php")

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 detected2,495 lines of code in 34 files:
LanguageFilesBlank linesComment linesLines of code
PHP112,1899851,701
CSS2147204461
JavaScript334082244
XML180089

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity37.40
▷ Minimum class complexity19.00
▷ Maximum class complexity62.00
Average method complexity3.70
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods64
▷ Static methods1117.19%
▷ Public methods4976.56%
▷ Protected methods34.69%
▷ Private methods1218.75%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants375.00%
▷ Class constants125.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
10 PNG files occupy 0.20MB with 0.12MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/upvote.png5.01KB1.20KB▼ 76.06%
assets/upvote2.png1.94KB0.82KB▼ 57.70%
assets/banner-772x250.png11.50KB5.06KB▼ 56.00%
assets/downvote2.png2.01KB0.82KB▼ 59.14%
public/assets/images/official logo.png21.25KB8.41KB▼ 60.45%