84% press-this-new-post

Code Review | Press This New Post

WordPress plugin Press This New Post scored84%from 54 tests.

About plugin

  • Plugin page: press-this-new-post
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1.0-4.7.0
  • WordPress version: 6.3.1
  • First release: Apr 24, 2015
  • Latest release: Dec 9, 2016
  • Number of updates: 8
  • Update frequency: every 74.4 days
  • Top authors: DrewAPicture (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /5,172 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.01MB] [CPU: ▼3.65ms] Passed 4 tests

An overview of server-side resources used by Press This New Post
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.35 ▼10.08
Dashboard /wp-admin3.31 ▲0.0145.03 ▼4.49
Posts /wp-admin/edit.php3.36 ▲0.0144.99 ▲0.34
Add New Post /wp-admin/post-new.php5.89 ▲0.0186.69 ▼0.37
Media Library /wp-admin/upload.php3.23 ▲0.0133.04 ▲2.51

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Press This New Post
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6014.47 ▼0.111.66 ▼0.2642.45 ▼1.44
Dashboard /wp-admin2,209 ▲215.85 ▼0.0099.94 ▼14.0637.08 ▼10.09
Posts /wp-admin/edit.php2,092 ▲32.04 ▲0.0434.87 ▼3.2232.11 ▼2.93
Add New Post /wp-admin/post-new.php1,540 ▲623.58 ▲0.45581.68 ▼63.0460.42 ▲4.05
Media Library /wp-admin/upload.php1,391 ▼04.20 ▲0.0395.66 ▼6.2642.51 ▼1.12

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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 trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/press-this-new-post/press-this-new-post.php:25

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: press this, posting, new post

press-this-new-post/press-this-new-post.php Passed 13 tests

The primary PHP file in "Press This New Post" version 1.0 is used by WordPress to initiate all plugin functionality
99 characters long description:
Adds a 'Press This' item to the '+ New' drop-down in the Toolbar for directly accessing Press This.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected15 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP142715

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.00
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
There were not PNG files found in your plugin