84% tekserve-press-mentions

Code Review | Tekserve Press Mentions

WordPress plugin Tekserve Press Mentions scored84%from 54 tests.

About plugin

  • Plugin page: tekserve-press-me...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-3.7.1
  • WordPress version: 6.3.1
  • First release: Nov 8, 2013
  • Latest release: Nov 10, 2013
  • Number of updates: 7
  • Update frequency: every 0.3 days
  • Top authors: bangerkuwranger (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /769 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼2.66ms] Passed 4 tests

This is a short check of server-side resources used by Tekserve Press Mentions
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0438.50 ▼3.69
Dashboard /wp-admin3.34 ▲0.0448.45 ▼0.85
Posts /wp-admin/edit.php3.39 ▲0.0447.12 ▲1.06
Add New Post /wp-admin/post-new.php5.92 ▲0.0483.31 ▼7.16
Media Library /wp-admin/upload.php3.26 ▲0.0441.48 ▲8.43
Add New /wp-admin/post-new.php?post_type=tekserve_press3.4046.82
Press Mentions /wp-admin/edit.php?post_type=tekserve_press3.3136.36

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Tekserve Press Mentions
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,832 ▲8613.18 ▼1.201.67 ▼0.1842.14 ▼5.40
Dashboard /wp-admin2,233 ▲484.88 ▼1.09102.31 ▼10.3838.15 ▼8.11
Posts /wp-admin/edit.php2,116 ▲271.98 ▼0.0335.08 ▼2.4534.39 ▼0.65
Add New Post /wp-admin/post-new.php1,556 ▲2223.44 ▲0.24676.15 ▲63.6849.01 ▼4.06
Media Library /wp-admin/upload.php1,412 ▲214.30 ▲0.09105.77 ▲6.1544.33 ▲1.73
Add New /wp-admin/post-new.php?post_type=tekserve_press2,5227.73163.6464.57
Press Mentions /wp-admin/edit.php?post_type=tekserve_press1,1231.9331.4231.19

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

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
Please fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/tekserve-press-mentions/single-tekserve_press.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/tekserve-press-mentions/tekserve-press-mentions.php:24

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 errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 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
Attributes that need to be fixed:
  • Screenshots: Screenshot #1 (This is pretty much it. Woo.) image not found
You can take inspiration from this readme.txt

tekserve-press-mentions/tekserve-press-mentions.php Passed 13 tests

The principal PHP file in "Tekserve Press Mentions" v. 1.1 is loaded by WordPress automatically on each request
59 characters long description:
Custom Post Type for Press Mentions; Includes Custom Fields

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin155 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP22733112
Markdown126037
CSS1006

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.44
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%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
1 PNG file occupies 0.16MB with 0.11MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png164.20KB49.08KB▼ 70.11%