84% theme-search

Code Review | Theme Search

WordPress plugin Theme Search scored84%from 54 tests.

About plugin

  • Plugin page: theme-search
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.3
  • WordPress version: 6.3.1
  • First release: Sep 25, 2015
  • Latest release: Sep 25, 2015
  • Number of updates: 4
  • Update frequency: every 0.3 days
  • Top authors: sgrant (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,276 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

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

An overview of server-side resources used by Theme Search
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0144.60 ▲6.59
Dashboard /wp-admin3.31 ▲0.0149.29 ▲0.74
Posts /wp-admin/edit.php3.37 ▲0.0147.93 ▼10.55
Add New Post /wp-admin/post-new.php5.90 ▲0.0187.31 ▼6.47
Media Library /wp-admin/upload.php3.24 ▲0.0137.29 ▲2.36
Theme Search /wp-admin/themes.php?page=theme-search3.2034.64

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_recent-posts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Theme Search
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.27 ▼0.101.64 ▼0.0341.95 ▼2.00
Dashboard /wp-admin2,202 ▲255.63 ▼0.0588.21 ▼9.8038.39 ▼2.01
Posts /wp-admin/edit.php2,104 ▲12.01 ▼0.0137.43 ▼9.2434.27 ▼3.26
Add New Post /wp-admin/post-new.php1,540 ▲1218.39 ▼4.87657.16 ▼54.3075.91 ▲22.87
Media Library /wp-admin/upload.php1,398 ▼54.16 ▼0.0496.94 ▼6.8544.53 ▼3.31
Theme Search /wp-admin/themes.php?page=theme-search7682.2824.5734.59

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
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/theme-search/theme-search.php:19

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: theme search, theme, search

theme-search/theme-search.php Passed 13 tests

"Theme Search" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
55 characters long description:
Search for content inside of the active WordPress theme

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin45 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1141145

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG files were detected