73% uptopromo-publisher-indonesia

Code Review | Uptopromo Publisher Indonesia

WordPress plugin Uptopromo Publisher Indonesia scored73%from 54 tests.

About plugin

  • Plugin page: uptopromo-publish...
  • Plugin version: 0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-3.5
  • WordPress version: 6.3.1
  • First release: Jul 16, 2015
  • Latest release: Jan 21, 2016
  • Number of updates: 4
  • Update frequency: every 47.3 days
  • Top authors: ipnino (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,388 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▼0.94MB] [CPU: ▼38.48ms] Passed 4 tests

Server-side resources used by Uptopromo Publisher Indonesia
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0242.26 ▼4.62
Dashboard /wp-admin3.01 ▼0.3022.25 ▼35.53
Posts /wp-admin/edit.php3.01 ▼0.3524.57 ▼31.51
Add New Post /wp-admin/post-new.php3.01 ▼2.8823.12 ▼71.96
Media Library /wp-admin/upload.php3.01 ▼0.2220.83 ▼14.93

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 12 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
promo_userhash
promo_password
promo_token
promo_platformid
promo_email
widget_recent-posts
db_upgraded
...

Browser metrics Passed 4 tests

Uptopromo Publisher Indonesia: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,918 ▲17214.00 ▼0.407.01 ▲5.2944.66 ▼1.76
Dashboard /wp-admin2,218 ▲664.85 ▼0.85107.22 ▲7.2037.60 ▼6.23
Posts /wp-admin/edit.php2,101 ▲121.99 ▼0.0639.27 ▲1.5435.66 ▼1.11
Add New Post /wp-admin/post-new.php1,523 ▲917.81 ▲0.26662.17 ▼25.2465.81 ▲10.78
Media Library /wp-admin/upload.php1,397 ▲184.16 ▼0.01104.52 ▼3.1045.02 ▼1.98

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Uninstall procedure had uncaught errors
    • > User deprecated in wp-includes/functions.php+5453
    Function add_utility_page is deprecated since version 4.5.0! Use add_menu_page() instead.
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts

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
Good news, no errors were detected

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 take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/uptopromo-publisher-indonesia/uptopromo.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Plugin Name: Please specify the plugin name on the first line ( === uptopromo-publisher-indonesia === )
You can look at the official readme.txt

uptopromo-publisher-indonesia/uptopromo.php 85% from 13 tests

The principal PHP file in "Uptopromo Publisher Indonesia" v. 0.2 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Description: Please keep the plugin description shorter than 140 characters (currently 220 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("uptopromo-publisher-indonesia.php" instead of "uptopromo.php")

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
There were no executable files found in this plugin920 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP219038901
JavaScript13019

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.51
Average class complexity105.00
▷ Minimum class complexity53.00
▷ Maximum class complexity157.00
Average method complexity8.43
▷ Minimum method complexity1.00
▷ Maximum method complexity50.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods28
▷ Static methods00.00%
▷ Public methods2589.29%
▷ Protected methods00.00%
▷ Private methods310.71%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin