10% post-via-dropbox

Code Review | Post via Dropbox

WordPress plugin Post via Dropbox scored10%from 54 tests.

About plugin

  • Plugin page: post-via-dropbox
  • Plugin version: 2.20
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-4.9.5
  • WordPress version: 6.3.1
  • First release: Oct 23, 2012
  • Latest release: May 10, 2018
  • Number of updates: 21
  • Update frequency: every 96.5 days
  • Top authors: PaoloBe (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

10+ active /6,440 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
It is recommended to fix the following installer errors
  • Install procedure had errors
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+265
    Undefined index: pvd_unlink

Server metrics [RAM: ▼1.96MB] [CPU: ▼46.47ms] Passed 4 tests

Server-side resources used by Post via Dropbox
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.439.70 ▼29.94
Dashboard /wp-admin2.05 ▼1.268.50 ▼43.58
Posts /wp-admin/edit.php2.05 ▼1.316.78 ▼36.15
Add New Post /wp-admin/post-new.php2.05 ▼3.847.28 ▼76.21
Media Library /wp-admin/upload.php2.05 ▼1.186.87 ▼27.60
Post via Dropbox /wp-admin/options-general.php?page=pvd-settings2.056.94

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 214 new files
Database: no new tables, 10 new options
New WordPress options
can_compress_scripts
pvd_errors
pvd_encryptkey
db_upgraded
widget_theysaidso_widget
widget_recent-posts
pvd_logs
widget_recent-comments
pvd_options
theysaidso_admin_options

Browser metrics Passed 4 tests

Post via Dropbox: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.20 ▼1.111.66 ▼0.3038.60 ▼5.98
Dashboard /wp-admin2,210 ▲285.77 ▲0.88102.04 ▼14.8239.21 ▼5.26
Posts /wp-admin/edit.php2,090 ▲12.06 ▲0.0434.87 ▼1.6030.07 ▼4.28
Add New Post /wp-admin/post-new.php1,536 ▲323.25 ▼0.02668.12 ▼34.4452.36 ▲2.62
Media Library /wp-admin/upload.php1,395 ▲44.18 ▼0.0399.33 ▼1.9146.67 ▲1.64
Post via Dropbox /wp-admin/options-general.php?page=pvd-settings1,3681.6926.3432.91

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+265
    Undefined index: pvd_unlink
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+265
    Undefined index: pvd_unlink
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+829
    Undefined index: error
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+325
    Undefined variable: access_token
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+104
    Undefined index: delete
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+106
    Undefined index: simplified
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+107
    Undefined index: author
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+109
    Undefined index: cat
    • > GET request to /wp-admin/options-general.php?page=pvd-settings
    • > Notice in wp-content/plugins/post-via-dropbox/pvd.php+130
    Undefined index: restart

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 106× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Kunnu\\Dropbox\\Models\\BaseModel' not found in wp-content/plugins/post-via-dropbox/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Models/CopyReference.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'Dropbox\\OAuth\\Storage\\Session' not found in wp-content/plugins/post-via-dropbox/dropbox/PDO.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Promise\\RejectionException' not found in wp-content/plugins/post-via-dropbox/vendor/guzzlehttp/promises/src/CancellationException.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/post-via-dropbox/vendor/guzzlehttp/psr7/src/PumpStream.php:16
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\MessageInterface' not found in wp-content/plugins/post-via-dropbox/vendor/psr/http-message/src/RequestInterface.php:24
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/post-via-dropbox/vendor/guzzlehttp/promises/src/RejectedPromise.php:10
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\UploadedFileInterface' not found in wp-content/plugins/post-via-dropbox/vendor/guzzlehttp/psr7/src/UploadedFile.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Cookie\\CookieJar' not found in wp-content/plugins/post-via-dropbox/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Kunnu\\Dropbox\\Models\\BaseModel' not found in wp-content/plugins/post-via-dropbox/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Models/AccessToken.php:4
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\ResponseInterface' not found in wp-content/plugins/post-via-dropbox/vendor/guzzlehttp/psr7/src/Response.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: post, remote update, post via dropbox, posting, remote...

post-via-dropbox/pvd.php 92% from 13 tests

The primary PHP file in "Post via Dropbox" version 2.20 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("post-via-dropbox.php" instead of "pvd.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
There were no executable files found in this plugin18,752 lines of code in 194 files:
LanguageFilesBlank linesComment linesLines of code
PHP1603,4079,95914,745
Markdown1395903,175
JSON700534
YAML6301124
XML50096
make323078

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity12.69
▷ Minimum class complexity1.00
▷ Maximum class complexity121.00
Average method complexity2.38
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces23
Interfaces22
Traits4
Classes122
▷ Abstract classes10.82%
▷ Concrete classes12199.18%
▷ Final classes75.79%
Methods1,221
▷ Static methods1038.44%
▷ Public methods96779.20%
▷ Protected methods12610.32%
▷ Private methods12810.48%
Functions183
▷ Named functions5932.24%
▷ Anonymous functions12467.76%
Constants78
▷ Global constants00.00%
▷ Class constants78100.00%
▷ Public constants78100.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 compressed PNG file occupies 0.02MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
vendor/tightenco/collect/collect-logo.png17.89KB16.65KB▼ 6.92%