10% automated-editing

Code Review | Automated Editing

WordPress plugin Automated Editing scored10%from 54 tests.

About plugin

  • Plugin page: automated-editing
  • Plugin version: 2.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-4.5
  • WordPress version: 6.3.1
  • First release: Dec 30, 2011
  • Latest release: Apr 9, 2016
  • Number of updates: 33
  • Update frequency: every 47.3 days
  • Top authors: tepelstreel (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,754 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Please fix the following installer errors
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/automated-editing/automated-editing.php+96
    Trying to access array offset on value of type null

Server metrics [RAM: ▼0.13MB] [CPU: ▼15.52ms] Passed 4 tests

Server-side resources used by Automated Editing
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0440.77 ▼1.69
Dashboard /wp-admin3.24 ▼0.0733.73 ▼20.14
Posts /wp-admin/edit.php3.30 ▼0.0638.30 ▼13.12
Add New Post /wp-admin/post-new.php5.49 ▼0.4069.75 ▼21.89
Media Library /wp-admin/upload.php3.24 ▲0.0129.96 ▼6.94
Automated Editing /wp-admin/options-general.php?page=automated-editing-settings3.2440.00

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Automated Editing
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲3314.23 ▼0.301.70 ▼0.2344.11 ▲4.39
Dashboard /wp-admin2,214 ▲375.56 ▼0.0283.57 ▼13.3367.97 ▲27.60
Posts /wp-admin/edit.php2,125 ▲221.99 ▲0.0341.72 ▼0.0034.70 ▼6.55
Add New Post /wp-admin/post-new.php1,553 ▲2722.98 ▼0.14710.80 ▲2.5055.38 ▼21.38
Media Library /wp-admin/upload.php1,416 ▲164.12 ▼0.11105.90 ▲6.0475.73 ▲31.47
Automated Editing /wp-admin/options-general.php?page=automated-editing-settings1,3095.3064.5166.69

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > User deprecated in wp-includes/functions.php+5828
    Hook contextual_help is deprecated since version 3.3.0! Use get_current_screen()->add_help_tab(), get_current_screen()->remove_help_tab() instead.
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > Notice in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php+353
    Undefined index: action
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > Notice in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php+152
    Undefined index: excerpt_length
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > Notice in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php+166
    Undefined index: excerpt_style
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > Notice in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php+158
    Undefined index: offset
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > Notice in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php+228
    Undefined index: exclude_from_excerpt
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=automated-editing-settings
    • > Notice in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php+228
    Trying to access array offset on value of type null

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'A5_OptionPage' not found in wp-content/plugins/automated-editing/class-lib/AED_AdminClass.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
10 plugin tags: automatic repair, multisite fix, network enabled, fix posts, multisite...

automated-editing/automated-editing.php 92% from 13 tests

This is the main PHP file of "Automated Editing" version 2.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 188 characters long)

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin2,427 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP61,8365452,004
PO File1115141341
JavaScript241682

PHP code 50% from 2 tests

A short review of cyclomatic complexity and code structure
The following items need your attention
  • Cyclomatic complexity of methods has to be reduced to less than 100 (currently 139)
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity71.67
▷ Minimum class complexity22.00
▷ Maximum class complexity256.00
Average method complexity5.76
▷ Minimum method complexity1.00
▷ Maximum method complexity139.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods89
▷ Static methods2528.09%
▷ Public methods8191.01%
▷ Protected methods00.00%
▷ Private methods88.99%
Functions29
▷ Named functions29100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants266.67%
▷ Class constants133.33%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
3 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/a5-icon-34.png1.65KB1.35KB▼ 18.07%
img/a5-icon-11.png0.67KB0.42KB▼ 37.17%
img/a5-icon-16.png0.77KB0.57KB▼ 25.99%