10% savtee-trade

Code Review | SavTee SEO

WordPress plugin SavTee SEO scored10%from 54 tests.

About plugin

  • Plugin page: savtee-trade
  • Plugin version: 1.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-4.9.8
  • WordPress version: 6.3.1
  • First release: Aug 13, 2018
  • Latest release: Aug 16, 2018
  • Number of updates: 9
  • Update frequency: every 0.6 days
  • Top authors: owlweb (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /621 total downloads

Benchmarks

Plugin footprint 23% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
It is recommended to fix the following installer errors
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/savtee-trade/classes/UPMain.php+55
    Undefined property: UpAjax::$_settings

Server metrics [RAM: ▼1.73MB] [CPU: ▼50.34ms] Passed 4 tests

Server-side resources used by SavTee SEO
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.26 ▼1.206.74 ▼34.68
Dashboard /wp-admin2.28 ▼1.036.21 ▼38.25
Posts /wp-admin/edit.php2.28 ▼1.086.72 ▼39.44
Add New Post /wp-admin/post-new.php2.28 ▼3.617.41 ▼89.00
Media Library /wp-admin/upload.php2.28 ▼0.956.59 ▼29.55
SavTee Settings /wp-admin/options-general.php?page=savtee-options2.287.75

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 30 new files
Database: 4 new tables, 10 new options
New tables
wp_savtee_favorites_3
wp_savtee_favorites_0
wp_savtee_favorites_2
wp_savtee_favorites_1
New WordPress options
post_title_maxchars
widget_theysaidso_widget
_yoast_wpseo_metadesc_maxchars
db_upgraded
can_compress_scripts
_yoast_wpseo_title_maxchars
theysaidso_admin_options
widget_recent-comments
note
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for SavTee SEO
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,837 ▲10213.13 ▼1.461.95 ▲0.2645.82 ▼3.06
Dashboard /wp-admin2,235 ▲445.90 ▲0.90107.81 ▲5.4240.25 ▼4.99
Posts /wp-admin/edit.php2,118 ▲262.03 ▲0.0337.26 ▲2.4034.70 ▲3.26
Add New Post /wp-admin/post-new.php6,555 ▲5,04120.16 ▲2.61924.57 ▲246.5759.10 ▲10.46
Media Library /wp-admin/upload.php1,417 ▲294.21 ▲0.05109.42 ▼7.1547.67 ▲5.51
SavTee Settings /wp-admin/options-general.php?page=savtee-options8712.0224.6429.49

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/savtee-trade/classes/UPMain.php+55
    Undefined property: UpAjax::$_settings
  • Zombie tables detected upon uninstall: 4 tables
    • wp_savtee_favorites_1
    • wp_savtee_favorites_0
    • wp_savtee_favorites_3
    • wp_savtee_favorites_2
  • Zombie WordPress options detected upon uninstall: 10 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • _yoast_wpseo_metadesc_maxchars
    • widget_recent-comments
    • db_upgraded
    • note
    • post_title_maxchars
    • can_compress_scripts
    • _yoast_wpseo_title_maxchars

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=savtee-options
    • > Notice in wp-content/plugins/savtee-trade/classes/UPMain.php+78
    Undefined property: UpAjax::$_settings
  • 9 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=savtee-options
    • > Notice in wp-content/plugins/savtee-trade/classes/UPMain.php+78
    Trying to access array offset on value of type null
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=savtee-options
    • > Notice in wp-content/plugins/savtee-trade/classes/UPMain.php+78
    Undefined property: UPAdminOptions::$_settings
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=savtee-options
    • > Notice in wp-content/plugins/savtee-trade/classes/UPMain.php+78
    Undefined property: UPAdminPlugin::$_settings
    • > GET request to /wp-admin/options-general.php?page=savtee-options
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

SRP 0% 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 output text when accessed directly:
    • > /wp-content/plugins/savtee-trade/includes/secure.php
  • 9× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_plugin_active() in wp-content/plugins/savtee-trade/includes/meta_tags.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'UPAjax' not found in wp-content/plugins/savtee-trade/http/ajax_functions.php:3
    • > PHP Warning
      include_once(): Failed opening 'ABSPATHwp-admin/includes/plugin.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/savtee-trade/includes/meta_tags.php on line 3
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/savtee-trade/includes/meta_tags.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'UPMain' not found in wp-content/plugins/savtee-trade/classes/UPAdminOptions.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'UPMain' not found in wp-content/plugins/savtee-trade/classes/UPAjax.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/savtee-trade/savtee.php:23
    • > PHP Warning
      include_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/savtee-trade/includes/meta_tags.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'UPMain' not found in wp-content/plugins/savtee-trade/classes/UPAdminPlugin.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: editing, yoast, seo, savtee

savtee-trade/savtee.php 85% from 13 tests

The primary PHP file in "SavTee SEO" version 1.0 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("savtee-trade.php" instead of "savtee.php")
  • Description: Please improve your description making it at least 10 characters long (currently 2 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin1,988 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP14224651,395
JavaScript69858488
CSS1271105

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity15.25
▷ Minimum class complexity8.00
▷ Maximum class complexity24.00
Average method complexity1.92
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods62
▷ Static methods00.00%
▷ Public methods2845.16%
▷ Protected methods1320.97%
▷ Private methods2133.87%
Functions17
▷ Named functions1164.71%
▷ Anonymous functions635.29%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
6 PNG files occupy 1.40MB with 0.73MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/banner-1544x500.png1,253.25KB457.36KB▼ 63.51%
assets/screenshot-3.png16.50KB7.19KB▼ 56.45%
assets/screenshot-2.png33.82KB14.93KB▼ 55.87%
assets/icon-128x128.png2.17KB1.50KB▼ 30.80%
assets/screenshot-1.png113.06KB50.30KB▼ 55.51%