84% theme-blvd-string-swap

Code Review | Theme Blvd String Swap

WordPress plugin Theme Blvd String Swap scored84%from 54 tests.

About plugin

  • Plugin page: theme-blvd-string...
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jan 30, 2012
  • Latest release: Jan 18, 2018
  • Number of updates: 24
  • Update frequency: every 90.8 days
  • Top authors: themeblvd (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active /8,094 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
The plugin installed gracefully, with no errors

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

A check of server-side resources used by Theme Blvd String Swap
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0038.18 ▲3.76
Dashboard /wp-admin3.31 ▼0.0344.11 ▼16.66
Posts /wp-admin/edit.php3.36 ▲0.0044.88 ▼4.55
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.15 ▼23.28
Media Library /wp-admin/upload.php3.23 ▲0.0038.52 ▲4.19

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Theme Blvd String Swap
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.27 ▼1.094.99 ▲3.2138.30 ▼4.93
Dashboard /wp-admin2,209 ▲235.86 ▲0.95101.54 ▼5.9848.47 ▲4.31
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0634.78 ▼4.0041.54 ▲9.37
Add New Post /wp-admin/post-new.php1,535 ▼323.24 ▲4.94674.81 ▲30.3060.17 ▲6.21
Media Library /wp-admin/upload.php1,388 ▲34.19 ▲0.0397.14 ▼6.0741.70 ▼3.14

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/theme-blvd-string-swap/themeblvd-string-swap.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 93% 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
These attributes need to be fixed:
  • Requires at least: Invalid plugin version format
You can take inspiration from this readme.txt

theme-blvd-string-swap/themeblvd-string-swap.php 92% from 13 tests

This is the main PHP file of "Theme Blvd String Swap" version 1.1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("theme-blvd-string-swap.php" instead of "themeblvd-string-swap.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected124 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP18693124

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
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%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected