83% google-drive-upload-and-download-link

Code Review | Google Drive upload and download link

WordPress plugin Google Drive upload and download link scored83%from 54 tests.

About plugin

  • Plugin page: google-drive-uplo...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 1.0-1.0
  • WordPress version: 6.3.1
  • First release: Mar 9, 2013
  • Latest release: Mar 9, 2013
  • Number of updates: 6
  • Update frequency: every 0.2 days
  • Top authors: oscaruh (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /5,580 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

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

A check of server-side resources used by Google Drive upload and download link
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.28 ▼4.34
Dashboard /wp-admin3.31 ▲0.0143.87 ▼7.12
Posts /wp-admin/edit.php3.36 ▲0.0143.22 ▼2.58
Add New Post /wp-admin/post-new.php5.89 ▲0.0180.63 ▼10.08
Media Library /wp-admin/upload.php3.23 ▲0.0135.68 ▲0.76

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Google Drive upload and download link: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9013.18 ▼1.475.18 ▲3.5044.61 ▲0.56
Dashboard /wp-admin2,209 ▲275.85 ▲0.9799.26 ▼12.2337.69 ▼10.12
Posts /wp-admin/edit.php2,086 ▼02.00 ▼0.0133.60 ▼3.1934.14 ▲2.55
Add New Post /wp-admin/post-new.php1,542 ▲2818.16 ▲0.60602.93 ▼81.8449.48 ▼5.60
Media Library /wp-admin/upload.php1,391 ▲64.20 ▼0.0395.03 ▼3.3444.21 ▼2.68

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
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget

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)
Everything seems fine, however this is by no means an exhaustive test

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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/google-drive-upload-and-download-link/pickergoogledirve.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Add an image for screenshot #1 (Selecciona el archivo y presiona select para que se inserte el enlace dentro del post|Select the file and press select to insert the link into the post http://develoteca.com/plugin-para-wordpress-de-google-drive-para-insertar-archivos-de-descarga/)
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === google-drive-upload-and-download-link === )
You can look at the official readme.txt

google-drive-upload-and-download-link/pickergoogledirve.php 92% from 13 tests

The main PHP file in "Google Drive upload and download link" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
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 ("google-drive-upload-and-download-link.php" instead of "pickergoogledirve.php")

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
Everything looks great! No dangerous files found in this plugin47 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP17947

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.08
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%
Functions3
▷ Named functions3100.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
1 PNG file occupies 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png37.12KB12.50KB▼ 66.32%