88% postem-ipsum

Code Review | Postem Ipsum

WordPress plugin Postem Ipsum scored 88% from 54 tests.

About plugin

  • Plugin page: postem-ipsum
  • Plugin version: 3.0.1
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.2
  • WordPress version: 5.8.1
  • First release: May 1, 2018
  • Latest release: Oct 23, 2019
  • Number of updates: 64
  • Update frequency: every 8.5 days
  • Top authors: franciscopalacios (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,253 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.25MB] [CPU: ▼135.78ms] Passed 4 tests

A check of server-side resources used by Postem Ipsum
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.09 ▲0.2538.72 ▲5.56
Dashboard /wp-admin3.32 ▲0.2646.95 ▲1.53
Posts /wp-admin/edit.php3.43 ▲0.3248.10 ▲6.00
Add New Post /wp-admin/post-new.php5.68 ▲0.2592.82 ▼551.74
Media Library /wp-admin/upload.php3.26 ▲0.2536.75 ▲1.55
Taxonomy terms /wp-admin/admin.php?page=postem-ipsum-terms-settings3.2531.34
Users /wp-admin/admin.php?page=postem-ipsum-users-settings3.2530.81
Generic Posts /wp-admin/admin.php?page=postem-ipsum-general-settings3.3232.25

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 31 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Postem Ipsum
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,754 ▲15815.76 ▲0.159.68 ▲0.2250.86 ▲3.96
Dashboard /wp-admin3,012 ▲815.91 ▼0.36143.54 ▲0.59113.75 ▼2.35
Posts /wp-admin/edit.php2,778 ▲392.72 ▲0.0064.24 ▲3.5493.54 ▲6.43
Add New Post /wp-admin/post-new.php1,708 ▲20818.71 ▲0.14372.38 ▼2.31106.39 ▼7.35
Media Library /wp-admin/upload.php1,846 ▲395.03 ▼0.02142.79 ▼15.01123.56 ▼1.89
Taxonomy terms /wp-admin/admin.php?page=postem-ipsum-terms-settings1,2633.1260.3486.04
Users /wp-admin/admin.php?page=postem-ipsum-users-settings1,2582.9060.5487.36
Generic Posts /wp-admin/admin.php?page=postem-ipsum-general-settings2,3382.6483.1389.57

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
This plugin's uninstaller ran successfully

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

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

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/postem-ipsum/admin/views/notice.php
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/postem-ipsum/admin/views/postem_ipsum_woo_settings.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/postem-ipsum/admin/views/postem_ipsum_get_taxonomies.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/postem-ipsum/admin/views/postem_ipsum_get_terms.php:1

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: Add descriptions for screenshots #1, #2, #3, #4 in postem-ipsum/assets to your readme.txt
You can take inspiration from this readme.txt

postem-ipsum/postem-ipsum.php Passed 13 tests

The principal PHP file in "Postem Ipsum" v. 3.0.1 is loaded by WordPress automatically on each request
47 characters long description:
Plugin to create some random posts from scratch

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
There were no executable files found in this plugin6,230 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript38724592,773
PHP165521662,072
CSS3821761,048
PO File2148268326
Markdown12011

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity85.50
▷ Minimum class complexity1.00
▷ Maximum class complexity170.00
Average method complexity5.12
▷ Minimum method complexity1.00
▷ Maximum method complexity69.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods41
▷ Static methods00.00%
▷ Public methods4097.56%
▷ Protected methods00.00%
▷ Private methods12.44%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot.4.png18.75KB7.81KB▼ 58.34%