84% anti-spambot-email-button

Code Review | Anti SpamBot Email Button

WordPress plugin Anti SpamBot Email Button scored84%from 54 tests.

About plugin

  • Plugin page: anti-spambot-emai...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.1
  • WordPress version: 6.3.1
  • First release: Nov 19, 2012
  • Latest release: Dec 18, 2014
  • Number of updates: 7
  • Update frequency: every 108.4 days
  • Top authors: Tibor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active /1,899 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Anti SpamBot Email Button
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.10 ▼6.11
Dashboard /wp-admin3.32 ▼0.0350.86 ▼9.43
Posts /wp-admin/edit.php3.37 ▲0.0151.94 ▼1.01
Add New Post /wp-admin/post-new.php5.90 ▲0.0198.04 ▼11.22
Media Library /wp-admin/upload.php3.24 ▲0.0136.83 ▲3.30

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

A check of browser resources used by Anti SpamBot Email Button
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲4314.35 ▲0.221.75 ▼0.0740.75 ▲2.09
Dashboard /wp-admin2,192 ▲155.54 ▼0.1588.45 ▼1.1540.60 ▼0.24
Posts /wp-admin/edit.php2,100 ▼02.03 ▲0.0436.08 ▼2.5235.00 ▲0.29
Add New Post /wp-admin/post-new.php1,526 ▼923.00 ▲4.65648.34 ▼40.7854.33 ▼9.65
Media Library /wp-admin/upload.php1,394 ▼64.18 ▼0.0298.43 ▼6.5143.57 ▼3.27

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means 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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/anti-spambot-email-button/email-shortcode-button.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found


Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
4 plugin tags: shortcode, email, admin, spam

anti-spambot-email-button/email-shortcode-button.php 92% from 13 tests

The entry point to "Anti SpamBot Email Button" version 1.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("anti-spambot-email-button.php" instead of "email-shortcode-button.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected44 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.27
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 functions4100.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
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png27.95KB7.53KB▼ 73.07%
lib/email.png1.17KB0.97KB▼ 16.90%