84% affylite

Code Review | Affiliate Disclosure and Disclaimer - Affylite

WordPress plugin Affiliate Disclosure and Disclaimer - Affylite scored84%from 54 tests.

About plugin

  • Plugin page: affylite
  • Plugin version: 1.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.5
  • WordPress version: 6.3.1
  • First release: Jul 21, 2020
  • Latest release: Sep 27, 2020
  • Number of updates: 17
  • Update frequency: every 3.9 days
  • Top authors: heyjohncorbin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /1,478 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.33MB] [CPU: ▼19.79ms] Passed 4 tests

Server-side resources used by Affiliate Disclosure and Disclaimer - Affylite
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.44 ▼0.0338.63 ▼1.88
Dashboard /wp-admin3.32 ▼0.0246.29 ▼16.64
Posts /wp-admin/edit.php3.38 ▲0.0247.00 ▼0.68
Add New Post /wp-admin/post-new.php4.62 ▼1.2742.80 ▼59.96
Media Library /wp-admin/upload.php3.25 ▲0.0140.56 ▲4.45

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

Checking browser requirements for Affiliate Disclosure and Disclaimer - Affylite
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲4513.67 ▼0.471.95 ▲0.0043.45 ▲0.33
Dashboard /wp-admin2,219 ▲345.94 ▲0.08101.21 ▼2.4137.67 ▼6.53
Posts /wp-admin/edit.php2,105 ▲162.02 ▼0.0339.59 ▼1.7837.08 ▼0.15
Add New Post /wp-admin/post-new.php1,527 ▲1317.39 ▼0.02676.60 ▼10.7541.80 ▼12.97
Media Library /wp-admin/upload.php1,407 ▲194.28 ▲0.1098.01 ▼12.1041.09 ▼6.88

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

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
Please fix the following items
  • 1× 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/affylite/affylite.php:14

User-side errors Passed 1 test

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


Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Screenshots: Add a description for screenshot #1 in affylite/assets to your readme.txt
Please take inspiration from this readme.txt

affylite/affylite.php Passed 13 tests

The entry point to "Affiliate Disclosure and Disclaimer - Affylite" version 1.2 is a PHP file that has certain tags in its header comment area
110 characters long description:
Add a simple affiliate disclosure and disclaimer to the top of each post. Easy, lite, and no bloat. Under 5kb.

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
There were no executable files found in this plugin66 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.14
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
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions5100.00%
▷ Anonymous functions00.00%
▷ 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
No PNG files were detected