74% ajax-rating-with-custom-login

Code Review | Ajax Rating with Custom Login

WordPress plugin Ajax Rating with Custom Login scored74%from 54 tests.

About plugin

  • Plugin page: ajax-rating-with-...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.4.2
  • WordPress version: 6.3.1
  • First release: Feb 1, 2016
  • Latest release: Feb 8, 2016
  • Number of updates: 7
  • Update frequency: every 1.1 days
  • Top authors: anand23 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /858 total downloads

Benchmarks

Plugin footprint 65% 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.01MB] [CPU: ▼7.75ms] Passed 4 tests

Analyzing server-side resources used by Ajax Rating with Custom Login
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0234.86 ▼3.19
Dashboard /wp-admin3.32 ▲0.0142.70 ▼9.35
Posts /wp-admin/edit.php3.37 ▲0.0143.57 ▲2.05
Add New Post /wp-admin/post-new.php5.90 ▲0.0178.50 ▼16.87
Media Library /wp-admin/upload.php3.24 ▲0.0135.70 ▼1.58

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 18 new files
Database: 1 new table, 6 new options
New tables
wp_ratings
New WordPress options
db_upgraded
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Ajax Rating with Custom Login
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,940 ▲19413.63 ▼1.127.48 ▲5.8846.61 ▲5.46
Dashboard /wp-admin2,221 ▲365.83 ▼0.0695.36 ▼4.7538.02 ▼5.50
Posts /wp-admin/edit.php2,101 ▲122.05 ▲0.0534.22 ▼4.3934.07 ▼2.37
Add New Post /wp-admin/post-new.php1,543 ▲923.25 ▲0.08643.51 ▼31.3652.72 ▲1.47
Media Library /wp-admin/upload.php1,400 ▲94.19 ▼0.0294.44 ▼8.0146.21 ▲2.04

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 1 table in the database
    • wp_ratings
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 75% 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 | 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
  • 8× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ajax-rating-with-custom-login/functions/ajax_rating_query.php:65
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ajax-rating-with-custom-login/functions/ajax_login_query.php:25
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ajax-rating-with-custom-login/admin/mith_arcl_settings.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ajax-rating-with-custom-login/functions/login_form.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/ajax-rating-with-custom-login/ajax-rating-with-custom-login.php:34
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/ajax-rating-with-custom-login/functions/create_rating_table.php:24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ajax-rating-with-custom-login/functions/include_assets.php:42
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/ajax-rating-with-custom-login/shortcode/create_rating_shortcode.php:167

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% 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
9 plugin tags: bootstrap ajax login, ajax login, post rating, custom wordpress login, custom post...

ajax-rating-with-custom-login/ajax-rating-with-custom-login.php 92% from 13 tests

The entry point to "Ajax Rating with Custom Login" version 1.1 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 245 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected337 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP811923300
JavaScript3131526
CSS341311

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.11
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%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin