79% display-medium-posts

Code Review | Display Medium Posts

WordPress plugin Display Medium Posts scored79%from 54 tests.

About plugin

  • Plugin page: display-medium-posts
  • Plugin version: 5.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.4.1
  • WordPress version: 6.3.1
  • First release: Oct 21, 2016
  • Latest release: May 25, 2020
  • Number of updates: 29
  • Update frequency: every 45.2 days
  • Top authors: acekyd (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

2,000+ active /24,641 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
Install script ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼1.04ms] Passed 4 tests

Analyzing server-side resources used by Display Medium Posts
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0836.61 ▼5.53
Dashboard /wp-admin3.38 ▲0.0750.33 ▼3.93
Posts /wp-admin/edit.php3.49 ▲0.1352.34 ▲5.17
Add New Post /wp-admin/post-new.php5.96 ▲0.0791.81 ▲0.15
Media Library /wp-admin/upload.php3.30 ▲0.0735.41 ▲5.34
Medium Posts /wp-admin/options-general.php?page=display-medium-posts3.3136.33

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Display Medium Posts
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,893 ▲15813.60 ▼0.697.98 ▲6.3239.51 ▼5.25
Dashboard /wp-admin2,207 ▲195.81 ▲0.7695.82 ▼18.4239.85 ▼9.13
Posts /wp-admin/edit.php2,096 ▲102.02 ▼0.0442.19 ▲5.1036.27 ▲1.92
Add New Post /wp-admin/post-new.php1,547 ▲3323.28 ▲5.72606.41 ▼80.6853.47 ▼6.72
Media Library /wp-admin/upload.php1,389 ▲14.18 ▼0.10100.69 ▼3.0341.14 ▼2.71
Medium Posts /wp-admin/options-general.php?page=display-medium-posts1,2193.4155.5628.82

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 50% 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)
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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 fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/display-medium-posts/public/partials/display-medium-posts-public-display.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/display-medium-posts/admin/partials/display-medium-posts-admin-display.php:19

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 Passed 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
4 plugin tags: mediumcom, posts, medium, shortcodes

display-medium-posts/display-medium-posts.php Passed 13 tests

Analyzing the main PHP file in "Display Medium Posts" version 5.0.1
120 characters long description:
Display Medium Posts is a wordpress plugin that allows users display posts from medium.com on any part of their website.

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 plugin2,059 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript4210711,341
PHP12162562424
CSS51836294

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity1.57
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.15
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods26
▷ Static methods27.69%
▷ Public methods2180.77%
▷ Protected methods00.00%
▷ Private methods519.23%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
public/vendors/owl-carousel/grabbing.png0.11KB0.14KB0.00%