84% woostagram-connect

Code Review | Woostagram Connect

WordPress plugin Woostagram Connect scored84%from 54 tests.

About plugin

  • Plugin page: woostagram-connect
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.0
  • WordPress version: 6.3.1
  • First release: Oct 14, 2014
  • Latest release: Oct 19, 2014
  • Number of updates: 11
  • Update frequency: every 0.5 days
  • Top authors: bepitulaz (100%)

Code review

54 tests

User reviews

1 review

Install metrics

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

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

Analyzing server-side resources used by Woostagram Connect
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0035.07 ▼6.09
Dashboard /wp-admin3.31 ▲0.0044.92 ▼7.30
Posts /wp-admin/edit.php3.36 ▲0.0046.75 ▲0.44
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.53 ▼11.78
Media Library /wp-admin/upload.php3.23 ▲0.0037.21 ▲0.83

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Woostagram Connect
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6514.51 ▲0.201.84 ▲0.1542.20 ▼1.86
Dashboard /wp-admin2,203 ▲145.83 ▲0.8793.54 ▼31.7637.91 ▼6.42
Posts /wp-admin/edit.php2,092 ▲242.05 ▲0.0440.48 ▲4.5233.53 ▲1.21
Add New Post /wp-admin/post-new.php1,532 ▼623.40 ▲0.29640.33 ▼43.6050.50 ▼9.12
Media Library /wp-admin/upload.php1,388 ▼34.28 ▲0.1096.01 ▼3.0740.59 ▼3.77

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded

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 no errors were found, 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
  • 5× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/woostagram-connect/navigation/options.php
    • > /wp-content/plugins/woostagram-connect/navigation/view_feed_woostagram.php
    • > /wp-content/plugins/woostagram-connect/woostagram.php
    • > /wp-content/plugins/woostagram-connect/oauth/auth.php
    • > /wp-content/plugins/woostagram-connect/navigation/view_woostagram_connect.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
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 undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
4 plugin tags: instagram, commerce, woocommerce, import

woostagram-connect/woostagram.php 92% from 13 tests

The main file in "Woostagram Connect" v. 1.0.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("woostagram-connect.php" instead of "woostagram.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 detected403 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP675113386
JavaScript14317

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity5.33
▷ Minimum class complexity2.00
▷ Maximum class complexity9.00
Average method complexity1.83
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods13
▷ Static methods00.00%
▷ Public methods1292.31%
▷ Protected methods00.00%
▷ Private methods17.69%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/instagram.png2.17KB1.26KB▼ 42.20%