74% ants-insight

Code Review | ANTS INSIGHT

WordPress plugin ANTS INSIGHT scored74%from 54 tests.

About plugin

  • Plugin page: ants-insight
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 1.0.0+
  • WordPress version: 6.3.1
  • First release: Jul 6, 2016
  • Latest release: Jul 6, 2016
  • Number of updates: 9
  • Update frequency: every 0.3 days
  • Top authors: bachdung87 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /587 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▼0.95MB] [CPU: ▼37.02ms] Passed 4 tests

A check of server-side resources used by ANTS INSIGHT
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0038.40 ▼12.26
Dashboard /wp-admin2.99 ▼0.3121.17 ▼28.92
Posts /wp-admin/edit.php2.99 ▼0.3622.64 ▼26.55
Add New Post /wp-admin/post-new.php2.99 ▼2.8919.19 ▼79.57
Media Library /wp-admin/upload.php2.99 ▼0.2323.68 ▼13.05

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for ANTS INSIGHT
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,811 ▲5014.20 ▼0.531.80 ▲0.0242.38 ▼0.51
Dashboard /wp-admin2,211 ▲315.63 ▼0.02100.53 ▲14.6344.78 ▲2.17
Posts /wp-admin/edit.php2,116 ▲161.97 ▼0.0140.81 ▲3.8935.65 ▲2.65
Add New Post /wp-admin/post-new.php1,539 ▲1323.33 ▼0.25664.55 ▲34.1863.37 ▲8.55
Media Library /wp-admin/upload.php1,416 ▲164.21 ▲0.03102.20 ▲1.0842.09 ▼0.36

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Uninstall procedure had uncaught errors
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means 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
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ants-insight/ANTS_INSIGHT.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
2 plugin tags: antsvn, ants insigth

ants-insight/ANTS_INSIGHT.php 92% from 13 tests

The main file in "ANTS INSIGHT" v. 1.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("ants-insight.php" instead of "ANTS_INSIGHT.php")

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
Success! There were no dangerous files found in this plugin64 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1241064

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin