90% the-publisher-desk-ads

Code Review | The Publisher Desk - Ads

WordPress plugin The Publisher Desk - Ads scored90%from 54 tests.

About plugin

  • Plugin page: the-publisher-des...
  • Plugin version: 1.0.3
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.0
  • WordPress version: 6.3.1
  • First release: Jan 7, 2021
  • Latest release: Nov 15, 2022
  • Number of updates: 5
  • Update frequency: every 135.4 days
  • Top authors: thepublisherdesk (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /570 total downloads

Benchmarks

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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼3.35ms] Passed 4 tests

Server-side resources used by The Publisher Desk - Ads
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.00 ▼2.82
Dashboard /wp-admin3.31 ▲0.0146.78 ▼1.92
Posts /wp-admin/edit.php3.36 ▲0.0149.72 ▼0.25
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.36 ▼8.39
Media Library /wp-admin/upload.php3.23 ▲0.0039.52 ▲6.55

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for The Publisher Desk - Ads
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲9213.69 ▼0.901.79 ▲0.1144.45 ▲0.36
Dashboard /wp-admin2,209 ▲214.85 ▼1.0699.88 ▼3.3738.96 ▼3.55
Posts /wp-admin/edit.php2,089 ▼32.00 ▼0.0036.56 ▼4.0431.91 ▼3.55
Add New Post /wp-admin/post-new.php6,248 ▲4,70619.89 ▲1.56887.90 ▲286.9955.32 ▼1.01
Media Library /wp-admin/upload.php1,388 ▼04.16 ▼0.0195.56 ▼4.5940.80 ▼4.53

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
4 plugin tags: banner, ad manager, ads, ad placement

the-publisher-desk-ads/plugin.php 92% from 13 tests

The main file in "The Publisher Desk - Ads" v. 1.0.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("the-publisher-desk-ads.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected7,335 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
JSON2007,026
JavaScript41918125
Sass341119
PHP295846
Markdown18017
CSS2002

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.22
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%
Functions1
▷ Named functions1100.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