84% mend-sticky-posts

Code Review | Mend Sticky Posts

WordPress plugin Mend Sticky Posts scored84%from 54 tests.

About plugin

  • Plugin page: mend-sticky-posts
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.4.2
  • WordPress version: 6.3.1
  • First release: Sep 24, 2012
  • Latest release: Sep 25, 2012
  • Number of updates: 5
  • Update frequency: every 0.6 days
  • Top authors: martinshopland (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,124 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.00MB] [CPU: ▼12.00ms] Passed 4 tests

Server-side resources used by Mend Sticky Posts
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.08 ▼3.53
Dashboard /wp-admin3.31 ▼0.0348.06 ▼26.35
Posts /wp-admin/edit.php3.37 ▲0.0153.00 ▼1.91
Add New Post /wp-admin/post-new.php5.90 ▲0.0189.66 ▼16.21
Media Library /wp-admin/upload.php3.24 ▲0.0136.74 ▲1.39

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

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

Browser metrics Passed 4 tests

Mend Sticky Posts: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲6914.73 ▲0.541.82 ▼0.1441.12 ▼2.46
Dashboard /wp-admin2,224 ▲185.90 ▲1.00100.25 ▼7.3737.87 ▼0.99
Posts /wp-admin/edit.php2,100 ▲32.01 ▲0.0035.57 ▼1.2533.04 ▼3.35
Add New Post /wp-admin/post-new.php1,540 ▲1423.32 ▼0.13663.64 ▼46.7167.80 ▲12.41
Media Library /wp-admin/upload.php1,391 ▼124.25 ▼0.01100.56 ▼2.0943.24 ▲0.53

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 50% 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
Please fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/mend-sticky-posts/mend-sticky-posts.php:39

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

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
1 plugin tags: core

mend-sticky-posts/mend-sticky-posts.php Passed 13 tests

The entry point to "Mend Sticky Posts" version 1.1 is a PHP file that has certain tags in its header comment area
75 characters long description:
Wordpress's Sticky Posts behaviour is still incomprehensible, let's fix it.

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
Success! There were no dangerous files found in this plugin36 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1112836

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity2.67
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.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

PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin