73% onscribe

Code Review | Onscribe

WordPress plugin Onscribe scored73%from 54 tests.

About plugin

  • Plugin page: onscribe
  • Plugin version: 0.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-4.1
  • WordPress version: 6.3.1
  • First release: Jul 15, 2014
  • Latest release: Jan 15, 2015
  • Number of updates: 5
  • Update frequency: every 36.8 days
  • Top authors: kdiweb (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /829 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

Server-side resources used by Onscribe
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0040.81 ▼26.18
Dashboard /wp-admin3.32 ▲0.0248.33 ▼2.56
Posts /wp-admin/edit.php3.37 ▲0.0251.66 ▼5.86
Add New Post /wp-admin/post-new.php5.93 ▲0.0486.73 ▼12.48
Media Library /wp-admin/upload.php3.24 ▲0.0232.97 ▼1.95
Onscribe /wp-admin/options-general.php?page=onscribe-admin3.1934.25

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Onscribe
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,808 ▲6213.37 ▼0.862.23 ▲0.0941.19 ▼2.37
Dashboard /wp-admin2,217 ▲325.86 ▲0.00109.76 ▼11.7937.97 ▼7.47
Posts /wp-admin/edit.php2,097 ▲82.03 ▲0.0139.69 ▲3.8434.68 ▼0.04
Add New Post /wp-admin/post-new.php6,266 ▲4,73326.11 ▲3.04858.10 ▲227.0874.88 ▲17.52
Media Library /wp-admin/upload.php1,396 ▲84.22 ▼0.02100.42 ▼7.3943.62 ▼3.48
Onscribe /wp-admin/options-general.php?page=onscribe-admin8051.7327.2029.72

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=onscribe-admin
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=onscribe-admin
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

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
Please fix the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/onscribe/embed.php
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/onscribe/settings.php:238
    • > PHP Notice
      Undefined variable: product in wp-content/plugins/onscribe/embed.php on line 18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/onscribe/settings.php:238

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

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: Please add images for these screenshots: #1 (Screenshot of the Settings > Onscribe page, where you can add your products), #2 (Highlight of the shortcode generator meta box and a sample of the shortcode itself), #3 (An example of the actual subscription buttons in a post)
Please take inspiration from this readme.txt

onscribe/onscribe.php Passed 13 tests

The entry point to "Onscribe" version 0.1.1 is a PHP file that has certain tags in its header comment area
74 characters long description:
Simple integration for Onscribe. Adds subscription buttons to any webpage.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin376 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP785145295
JavaScript1122768
CSS14113

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity4.67
▷ Minimum class complexity1.00
▷ Maximum class complexity21.00
Average method complexity2.47
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods15
▷ Static methods00.00%
▷ Public methods1493.33%
▷ Protected methods00.00%
▷ Private methods16.67%
Functions5
▷ Named functions5100.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
3 PNG files occupy 0.42MB with 0.24MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png86.28KB33.47KB▼ 61.20%
screenshot-2.png189.60KB85.35KB▼ 54.98%
screenshot-3.png152.22KB69.73KB▼ 54.19%