90% curated-posts

Code Review | Curated Posts

WordPress plugin Curated Posts scored90%from 54 tests.

About plugin

  • Plugin page: curated-posts
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.7.2
  • WordPress version: 6.3.1
  • First release: Feb 20, 2017
  • Latest release: Feb 20, 2017
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: banago (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /807 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
Installer ran successfully

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

An overview of server-side resources used by Curated Posts
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0738.46 ▼7.66
Dashboard /wp-admin3.37 ▲0.0747.52 ▼6.66
Posts /wp-admin/edit.php3.42 ▲0.0750.08 ▼0.17
Add New Post /wp-admin/post-new.php5.96 ▲0.0792.85 ▼8.04
Media Library /wp-admin/upload.php3.29 ▲0.0737.05 ▲1.31
Curated Posts /wp-admin/edit.php?post_type=curated_posts3.3438.64
Add New /wp-admin/post-new.php?post_type=curated_posts3.3343.12

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for Curated Posts
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,813 ▲2714.33 ▼0.442.03 ▼0.0340.25 ▼5.00
Dashboard /wp-admin2,219 ▲395.65 ▼0.0292.08 ▼12.3540.85 ▼3.20
Posts /wp-admin/edit.php2,124 ▲242.02 ▼0.0138.82 ▲2.6836.60 ▲0.02
Add New Post /wp-admin/post-new.php1,546 ▲1823.18 ▼0.14647.68 ▼42.3656.61 ▼5.00
Media Library /wp-admin/upload.php1,418 ▲214.22 ▲0.0598.94 ▼12.8843.78 ▼5.87
Curated Posts /wp-admin/edit.php?post_type=curated_posts1,0881.9929.9930.83
Add New /wp-admin/post-new.php?post_type=curated_posts1,6363.0059.7774.34

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests Passed 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 Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: curated, posts, option, content, pages...

curated-posts/curated.php 92% from 13 tests

Analyzing the main PHP file in "Curated Posts" version 1.0
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("curated-posts.php" instead of "curated.php")

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
Good job! No executable or dangerous file extensions detected323 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP14684195
JavaScript2158108
CSS22020

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity30.00
▷ Minimum class complexity30.00
▷ Maximum class complexity30.00
Average method complexity2.93
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods15
▷ Static methods960.00%
▷ Public methods1493.33%
▷ Protected methods00.00%
▷ Private methods16.67%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin