10% l7-display-posts

Code Review | L7 Display Posts

WordPress plugin L7 Display Posts scored10%from 54 tests.

About plugin

  • Plugin page: l7-display-posts
  • Plugin version: 0.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1.1-4.4.2
  • WordPress version: 6.3.1
  • First release: Dec 7, 2015
  • Latest release: Mar 30, 2016
  • Number of updates: 20
  • Update frequency: every 6.0 days
  • Top authors: jeffreysmattson (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,110 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The following installer errors require your attention
  • Install procedure had errors
    • > User notice in wp-includes/functions.php+5905
    Function add_shortcode was called incorrectly. Invalid shortcode name: Display Posts. Do not use spaces or reserved characters: & / < > [ ] = Please see Debugging in WordPress for more information. (This message was added in version 4.4.0.)

Server metrics [RAM: ▼1.18MB] [CPU: ▼43.78ms] Passed 4 tests

Analyzing server-side resources used by L7 Display Posts
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.79 ▼0.6713.21 ▼32.49
Dashboard /wp-admin2.83 ▼0.4818.48 ▼31.97
Posts /wp-admin/edit.php2.83 ▼0.5316.09 ▼33.55
Add New Post /wp-admin/post-new.php2.83 ▼3.0619.94 ▼77.12
Media Library /wp-admin/upload.php2.83 ▼0.4018.86 ▼15.48

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for L7 Display Posts
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.23 ▼1.171.69 ▲0.0044.01 ▲0.21
Dashboard /wp-admin2,206 ▲185.88 ▼0.0297.42 ▼9.7036.22 ▼5.21
Posts /wp-admin/edit.php2,089 ▼02.01 ▼0.0234.32 ▼3.3433.68 ▼1.20
Add New Post /wp-admin/post-new.php1,535 ▼723.38 ▲4.90590.68 ▼26.7660.06 ▼3.63
Media Library /wp-admin/upload.php1,388 ▼34.31 ▲0.1493.88 ▼5.7842.84 ▲1.63

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Uninstall procedure had uncaught errors
    • > User notice in wp-includes/functions.php+5905
    Function add_shortcode was called incorrectly. Invalid shortcode name: Display Posts. Do not use spaces or reserved characters: & / < > [ ] = Please see Debugging in WordPress for more information. (This message was added in version 4.4.0.)
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function the_author_link() in wp-content/plugins/l7-display-posts/partials/posts-temp.php:17
    • > PHP Notice
      Undefined variable: two_columns in wp-content/plugins/l7-display-posts/partials/posts-temp.php on line 11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/l7-display-posts/l7-display-posts.php:38

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
8 plugin tags: display, memcache, object, columns, show...

l7-display-posts/l7-display-posts.php 92% from 13 tests

The entry point to "L7 Display Posts" version 0.1.1 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected389 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP661264233
Sass13291
CSS23758
JavaScript35137

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.28
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
Namespaces3
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%
Functions13
▷ Named functions1292.31%
▷ Anonymous functions17.69%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.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
There are no PNG files in this plugin