84% pinecast-wp-sync

Code Review | Pinecast WordPress Sync

WordPress plugin Pinecast WordPress Sync scored84%from 54 tests.

About plugin

  • Plugin page: pinecast-wp-sync
  • Plugin version: 1.2.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.7
  • WordPress version: 6.3.1
  • First release: Jul 10, 2019
  • Latest release: Jan 5, 2022
  • Number of updates: 29
  • Update frequency: every 31.4 days
  • Top authors: pinecast (100%)

Code review

54 tests

User reviews

1 review

Install metrics

70+ active /6,022 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼7.41ms] Passed 4 tests

Analyzing server-side resources used by Pinecast WordPress Sync
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0235.96 ▼4.67
Dashboard /wp-admin3.32 ▲0.0248.13 ▼3.84
Posts /wp-admin/edit.php3.38 ▲0.0247.36 ▼7.48
Add New Post /wp-admin/post-new.php5.93 ▲0.0484.09 ▼13.65
Media Library /wp-admin/upload.php3.25 ▲0.0238.29 ▼1.34
Pinecast /wp-admin/options-general.php?page=pinecast3.2836.25

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

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

Browser metrics Passed 4 tests

Pinecast WordPress Sync: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲4514.28 ▼0.081.67 ▼0.0242.23 ▲2.48
Dashboard /wp-admin2,212 ▲355.52 ▼0.0987.07 ▼4.1438.04 ▼8.91
Posts /wp-admin/edit.php2,118 ▲152.01 ▼0.0334.57 ▼9.3737.35 ▼1.89
Add New Post /wp-admin/post-new.php1,547 ▲1923.19 ▲0.02594.67 ▼28.4753.51 ▼11.76
Media Library /wp-admin/upload.php1,420 ▲174.27 ▲0.0896.65 ▼7.0242.45 ▼0.78
Pinecast /wp-admin/options-general.php?page=pinecast1,1252.0625.3929.72

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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • 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 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Warning
      Use of undefined constant PINECAST_FILE - assumed 'PINECAST_FILE' (this will throw an Error in a future version of PHP) in wp-content/plugins/pinecast-wp-sync/pinecast.php on line 39
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Pinecast\\load_plugin_textdomain() in wp-content/plugins/pinecast-wp-sync/pinecast.php:72
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Pinecast\\load_plugin_textdomain() in wp-content/plugins/pinecast-wp-sync/pinecast/pinecast.php:72
    • > PHP Warning
      Use of undefined constant PINECAST_FILE - assumed 'PINECAST_FILE' (this will throw an Error in a future version of PHP) in wp-content/plugins/pinecast-wp-sync/pinecast/pinecast.php on line 39

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 93% 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
4 plugin tags: pinecast, sync, jsonfeed, podcast

pinecast-wp-sync/plugin.php 85% from 13 tests

The main PHP script in "Pinecast WordPress Sync" version 1.2.1 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("pinecast-wp-sync.php" instead of "plugin.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
Good job! No executable or dangerous file extensions detected19,500 lines of code in 50 files:
LanguageFilesBlank linesComment linesLines of code
JSON70017,167
PHP305601,0131,838
JavaScript73014214
CSS322139
Sass1212138
Markdown1203
SVG1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity16.67
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.68
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces5
Interfaces0
Traits0
Classes15
▷ Abstract classes00.00%
▷ Concrete classes15100.00%
▷ Final classes00.00%
Methods142
▷ Static methods2416.90%
▷ Public methods12789.44%
▷ Protected methods00.00%
▷ Private methods1510.56%
Functions36
▷ Named functions2672.22%
▷ Anonymous functions1027.78%
Constants2
▷ Global constants2100.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
No PNG images were found in this plugin