68% onetap

Code Review | oneTap - Easy Google Sign In Prompt

WordPress plugin oneTap - Easy Google Sign In Prompt scored68%from 54 tests.

About plugin

  • Plugin page: onetap
  • Plugin version: 1.0.9
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.2
  • WordPress version: 6.3.1
  • First release: Sep 14, 2022
  • Latest release: Aug 2, 2023
  • Number of updates: 14
  • Update frequency: every 23.0 days
  • Top authors: exlac (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

100+ active /2,738 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲1.32MB] [CPU: ▲3.52ms] Passed 4 tests

Server-side resources used by oneTap - Easy Google Sign In Prompt
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.77 ▲1.3150.05 ▲6.46
Dashboard /wp-admin4.61 ▲1.3157.40 ▲6.31
Posts /wp-admin/edit.php4.72 ▲1.3763.72 ▲13.44
Add New Post /wp-admin/post-new.php7.24 ▲1.3694.28 ▼7.33
Media Library /wp-admin/upload.php4.53 ▲1.3047.29 ▲8.63

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

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

Browser metrics Passed 4 tests

A check of browser resources used by oneTap - Easy Google Sign In Prompt
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,856 ▲11014.53 ▲0.283.73 ▲1.8537.22 ▼6.03
Dashboard /wp-admin2,237 ▲525.63 ▲0.76127.58 ▲15.7244.63 ▲2.89
Posts /wp-admin/edit.php2,120 ▲342.41 ▲0.3841.06 ▲3.4331.91 ▼3.44
Add New Post /wp-admin/post-new.php1,540 ▲1023.59 ▲0.03657.25 ▼23.2037.09 ▼15.01
Media Library /wp-admin/upload.php1,413 ▲284.97 ▲0.73100.80 ▼15.9842.85 ▼9.23

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 0% 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
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/onetap/view/admin-ui/settings.php
    • > /wp-content/plugins/onetap/vendor/phpcompatibility/php-compatibility/phpunit-bootstrap.php
  • 1144× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'PHP_CodeSniffer\\Tests\\Standards\\AbstractSniffUnitTest' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/Generic/Tests/PHP/ClosingPHPTagUnitTest.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'PHP_CodeSniffer\\Sniffs\\Sniff' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/Squiz/Sniffs/WhiteSpace/FunctionSpacingSniff.php:16
    • > PHP Fatal error
      Uncaught Error: Interface 'PHP_CodeSniffer\\Sniffs\\Sniff' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/Squiz/Sniffs/PHP/InnerFunctionsSniff.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'PHP_CodeSniffer\\Sniffs\\Sniff' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/Squiz/Sniffs/CSS/LowercaseStyleDefinitionSniff.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'phpseclib3\\Crypt\\Common\\AsymmetricKey' not found in wp-content/plugins/onetap/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC.php:54
    • > PHP Fatal error
      Uncaught Error: Class 'PHP_CodeSniffer\\Tests\\Standards\\AbstractSniffUnitTest' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/Squiz/Tests/PHP/CommentedOutCodeUnitTest.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'PHP_CodeSniffer\\Tests\\Standards\\AbstractSniffUnitTest' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/Squiz/Tests/Arrays/ArrayBracketSpacingUnitTest.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'PHP_CodeSniffer\\Tests\\Standards\\AbstractSniffUnitTest' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Standards/PEAR/Tests/Commenting/InlineCommentUnitTest.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'PHP_CodeSniffer\\Reports\\Report' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/src/Reports/Checkstyle.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'PHP_CodeSniffer\\Tests\\Core\\AbstractMethodUnitTest' not found in wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/tests/Core/Tokenizer/AnonClassParenthesisOwnerTest.php:14

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 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Screenshots: Add descriptions for screenshots #1, #2, #3, #4 in onetap/assets to your readme.txt
The official readme.txt might help

onetap/onetap.php 92% from 13 tests

"oneTap - Easy Google Sign In Prompt" version 1.0.9's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Requires at least: The required version number must match the one declared in readme.txt ("5.0" instead of "5.2")

Code Analysis 3% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Please make sure to remedy the following
  • Do not include executable or dangerous files in your plugin
    • .bat - Batch File in Windows
      • wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/bin/phpcbf.bat
      • wp-content/plugins/onetap/vendor/squizlabs/php_codesniffer/bin/phpcs.bat
327,101 lines of code in 2,129 files:
LanguageFilesBlank linesComment linesLines of code
PHP1,62235,16083,470157,595
JavaScript6734,87029,130144,875
Markdown432,71408,686
Pascal1232,8966,1176,126
XML1734127705,935
JSON25002,850
CSS41189100673
SVG2900170
XSD160130
Bourne Shell210044
DOS Batch241010
YAML1007

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
It is recommended to fix the following
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 418)
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity14.71
▷ Minimum class complexity1.00
▷ Maximum class complexity670.00
Average method complexity4.54
▷ Minimum method complexity1.00
▷ Maximum method complexity418.00
Code structure
Namespaces284
Interfaces54
Traits15
Classes1,419
▷ Abstract classes24317.12%
▷ Concrete classes1,17682.88%
▷ Final classes574.85%
Methods5,892
▷ Static methods80013.58%
▷ Public methods4,53576.97%
▷ Protected methods78113.26%
▷ Private methods5769.78%
Functions223
▷ Named functions6830.49%
▷ Anonymous functions15569.51%
Constants676
▷ Global constants14221.01%
▷ Class constants53478.99%
▷ Public constants48891.39%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/6f8660f3df8cdcc746a16451c1420363.png1.00KB1.07KB0.00%