78% wp-postratings-cheater

Code Review | WP-PostRatings Cheater

WordPress plugin WP-PostRatings Cheater scored 78% from 54 tests.

About plugin

  • Plugin page: wp-postratings-ch...
  • Plugin version: 1.5
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-3.4.1
  • WordPress version: 6.3.1
  • First release: Nov 22, 2012
  • Latest release: Apr 21, 2015
  • Number of updates: 28
  • Update frequency: every 31.4 days
  • Top authors: queeez (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

800+ active / 11,087 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼1.30ms] Passed 4 tests

Analyzing server-side resources used by WP-PostRatings Cheater
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0140.67 ▼0.05
Dashboard /wp-admin3.31 ▲0.0146.40 ▼11.31
Posts /wp-admin/edit.php3.36 ▲0.0049.88 ▲2.98
Add New Post /wp-admin/post-new.php5.89 ▲0.0095.52 ▲5.40
Media Library /wp-admin/upload.php3.23 ▲0.0035.23 ▲3.17

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

WP-PostRatings Cheater: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲8113.34 ▼1.414.56 ▲2.5544.36 ▲0.09
Dashboard /wp-admin2,222 ▲434.85 ▼0.12107.44 ▼9.7739.06 ▼5.84
Posts /wp-admin/edit.php2,105 ▲161.97 ▼0.0540.47 ▲3.9935.85 ▲0.40
Add New Post /wp-admin/post-new.php1,546 ▲1323.20 ▲0.03646.72 ▼22.9252.69 ▼2.08
Media Library /wp-admin/upload.php1,407 ▲164.30 ▲0.12100.18 ▼1.5741.54 ▼3.15
Settings /wp-admin/wp-postratings-cheater-settings.php?page=wp-postratings-cheater/wp-postratings-cheater-settings.php260.440.0913.97

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-postratings-cheater/wp-postratings-cheater.php:33
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wp-postratings-cheater/wp-postratings-cheater-settings.php:20

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
These are user-side errors you should fix
    • > GET request to /wp-admin/wp-postratings-cheater-settings.php?page=wp-postratings-cheater/wp-postratings-cheater-settings.php
    • > Network (severe)
    wp-admin/wp-postratings-cheater-settings.php?page=wp-postratings-cheater/wp-postratings-cheater-settings.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: Screenshot #1 (Admin - Settings Menu) image required
The official readme.txt is a good inspiration

wp-postratings-cheater/wp-postratings-cheater.php Passed 13 tests

The main PHP file in "WP-PostRatings Cheater" ver. 1.5 adds more information about the plugin and also serves as the entry point for this plugin
89 characters long description:
If you use the famous wp-postratings plugin, you can now rate your articles like you want

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected134 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP24148134

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.30
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
Namespaces0
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png32.01KB18.66KB▼ 41.70%