84% saved-articles

Code Review | saved_articles

WordPress plugin saved_articles scored 84% from 54 tests.

About plugin

  • Plugin page: saved-articles
  • Plugin version: 0.1
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.2.1
  • WordPress version: 6.3.1
  • First release: Jun 3, 2019
  • Latest release: Jun 3, 2019
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: yurii1 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 519 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼9.97ms] Passed 4 tests

An overview of server-side resources used by saved_articles
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0546.73 ▼0.09
Dashboard /wp-admin3.34 ▲0.0355.08 ▲1.34
Posts /wp-admin/edit.php3.39 ▲0.0354.48 ▲1.07
Add New Post /wp-admin/post-new.php5.92 ▲0.0391.09 ▼38.01
Media Library /wp-admin/upload.php3.26 ▲0.0337.76 ▼2.84

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for saved_articles
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,926 ▲13713.67 ▼0.818.00 ▲6.0741.77 ▼7.41
Dashboard /wp-admin2,246 ▲374.88 ▲0.05108.45 ▼4.4545.61 ▲2.46
Posts /wp-admin/edit.php2,092 ▲32.01 ▲0.0139.35 ▲1.8236.02 ▲4.37
Add New Post /wp-admin/post-new.php1,514 ▼1917.54 ▼5.80703.59 ▲10.8558.81 ▲0.41
Media Library /wp-admin/upload.php1,391 ▲34.17 ▼0.1699.75 ▼10.5748.30 ▼0.76

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
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 take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/saved-articles/saved_articles.php:10

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
3 plugin tags: add to favorites, read later, remember the article

saved-articles/saved_articles.php 92% from 13 tests

The main PHP script in "saved_articles" version 0.1 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("saved-articles.php" instead of "saved_articles.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin234 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript200100
PHP231598
CSS20036

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.33
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
Namespaces0
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%
Functions9
▷ Named functions9100.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
PNG images were not found in this plugin