83% asc-mobile-bar

Code Review | ASC Mobile Bar

WordPress plugin ASC Mobile Bar scored83%from 54 tests.

About plugin

  • Plugin page: asc-mobile-bar
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.4
  • WordPress version: 6.3.1
  • First release: May 29, 2020
  • Latest release: May 30, 2020
  • Number of updates: 5
  • Update frequency: every 0.2 days
  • Top authors: jailsonpaca (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /437 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.01MB] [CPU: ▼5.28ms] Passed 4 tests

Analyzing server-side resources used by ASC Mobile Bar
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0144.58 ▲3.40
Dashboard /wp-admin3.31 ▲0.0154.34 ▲0.01
Posts /wp-admin/edit.php3.36 ▲0.0146.71 ▼2.32
Add New Post /wp-admin/post-new.php5.91 ▲0.0384.53 ▼19.35
Media Library /wp-admin/upload.php3.23 ▲0.0138.58 ▲0.56

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for ASC Mobile Bar
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,811 ▲5014.12 ▼0.621.82 ▲0.0040.24 ▼6.13
Dashboard /wp-admin2,215 ▲355.50 ▼0.1586.90 ▼12.8238.30 ▼4.49
Posts /wp-admin/edit.php2,120 ▲201.97 ▼0.0539.14 ▲0.3030.37 ▼8.23
Add New Post /wp-admin/post-new.php1,543 ▲1423.26 ▲0.34644.01 ▼45.2665.85 ▲7.03
Media Library /wp-admin/upload.php1,420 ▲234.17 ▲0.01108.60 ▲2.3746.03 ▲0.90

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

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 no errors were found, 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
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/asc-mobile-bar/wpsr.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (ASC-Mobile-Bar 1), #2 (ASC-Mobile-Bar 2), #3 (ASC-Mobile-Bar 3)
The official readme.txt is a good inspiration

asc-mobile-bar/wpsr.php 85% from 13 tests

The main PHP script in "ASC Mobile Bar" version 1.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("asc-mobile-bar.php" instead of "wpsr.php")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin530 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP12113299
CSS2101203
JavaScript10028

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.18
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%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected