78% ays-facebook-popup-likebox

Code Review | Popup Like box - Page Plugin

WordPress plugin Popup Like box - Page Plugin scored78%from 54 tests.

About plugin

  • Plugin page: ays-facebook-popu...
  • Plugin version: 3.7.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Mar 10, 2016
  • Latest release: Nov 28, 2023
  • Number of updates: 227
  • Update frequency: every 12.4 days
  • Top authors: ays-pro (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

200+ active /26,798 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.50MB] [CPU: ▲1.61ms] Passed 4 tests

Analyzing server-side resources used by Popup Like box - Page Plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /4.04 ▲0.5748.18 ▲5.90
Dashboard /wp-admin3.80 ▲0.5051.60 ▲4.00
Posts /wp-admin/edit.php3.84 ▲0.4847.46 ▼1.03
Add New Post /wp-admin/post-new.php6.45 ▲0.5685.91 ▼2.13
Media Library /wp-admin/upload.php3.68 ▲0.4538.52 ▲5.60
Facebook Popup Likebox /wp-admin/options-general.php?page=ays-facebook-popup-likebox3.7442.71

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 56 new files
Database: 1 new table, 9 new options
New tables
wp_ays_fbl
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-comments
can_compress_scripts
ays_fpl_banner_time
ays_fbl_db_version
ays_fpl_sale_btn
widget_recent-posts

Browser metrics Passed 4 tests

Popup Like box - Page Plugin: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,250 ▲47816.21 ▲1.8083.16 ▲81.2453.19 ▲8.19
Dashboard /wp-admin2,216 ▲365.52 ▼0.1487.04 ▼14.5182.18 ▲35.11
Posts /wp-admin/edit.php2,124 ▲242.01 ▼0.0038.21 ▼3.9636.18 ▼0.41
Add New Post /wp-admin/post-new.php1,547 ▲1223.15 ▼0.08690.75 ▲26.7136.67 ▼18.13
Media Library /wp-admin/upload.php1,424 ▲274.14 ▼0.0289.52 ▼10.2765.80 ▲23.57
Facebook Popup Likebox /wp-admin/options-general.php?page=ays-facebook-popup-likebox1,7255.49106.18127.92

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 8 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • ays_fpl_sale_btn
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • ays_fpl_banner_time

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/ays-facebook-popup-likebox/public/partials/ays-facebook-popup-likebox-public-display.php
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_bloginfo() in wp-content/plugins/ays-facebook-popup-likebox/admin/partials/actions/ays-facebook-popup-likebox-admin-actions.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/ays-facebook-popup-likebox/admin/partials/ays-facebook-popup-likebox-admin-display.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'WP_List_Table' not found in wp-content/plugins/ays-facebook-popup-likebox/includes/lists/class-fb-popup-likbox-list-table.php:3

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 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention: You can look at the official readme.txt

ays-facebook-popup-likebox/ays-facebook-popup-likebox.php Passed 13 tests

The primary PHP file in "Popup Like box - Page Plugin" version 3.7.2 is used by WordPress to initiate all plugin functionality
95 characters long description:
With the help of this amazing plugin you can promote your Facebook page and add number of Like

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin6,162 lines of code in 31 files:
LanguageFilesBlank linesComment linesLines of code
PHP145518823,211
CSS74623302,079
PO File1172218435
JavaScript65915374
SVG30063

PHP code 50% from 2 tests

Analyzing cyclomatic complexity and code structure
Please fix the following
  • Method cyclomatic complexity should be reduced to less than 100 (currently 111)
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity36.25
▷ Minimum class complexity1.00
▷ Maximum class complexity122.00
Average method complexity5.27
▷ Minimum method complexity1.00
▷ Maximum method complexity111.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods66
▷ Static methods812.12%
▷ Public methods5989.39%
▷ Protected methods00.00%
▷ Private methods710.61%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.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
13 PNG files occupy 0.71MB with 0.22MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/black-friday-great-bundle.png4.99KB4.89KB▼ 1.94%
admin/images/winter_bundle_logo_background_2.png357.75KB171.13KB▼ 52.16%
admin/images/black_friday_greate_bundle_mobile.png18.39KB18.43KB0.00%
admin/images/remove-normal.png2.75KB1.96KB▼ 28.81%
admin/images/winter_bundle_logo.png25.05KB6.65KB▼ 73.46%