10% currensees

Code Review | Currensees

WordPress plugin Currensees scored10%from 54 tests.

About plugin

  • Plugin page: currensees
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.2
  • WordPress version: 6.3.1
  • First release: May 4, 2023
  • Latest release: May 5, 2023
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: moatsystems (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /67 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
You still need to fix the following installer errors
  • This plugin did not install gracefully
    • > User error in wp-content/plugins/currensees/vendor/composer/platform_check.php+24
    Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.1.0". You are running 7.4.16.

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

A check of server-side resources used by Currensees
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0034.06 ▼2.73
Dashboard /wp-admin3.31 ▲0.0150.28 ▲0.62
Posts /wp-admin/edit.php3.36 ▲0.0048.07 ▼0.97
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.01 ▼17.39
Media Library /wp-admin/upload.php3.23 ▲0.0032.91 ▼3.27

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 1,733 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

Currensees: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲2913.23 ▼1.154.92 ▲3.0940.19 ▼0.86
Dashboard /wp-admin2,203 ▲265.77 ▼0.13104.87 ▲4.0137.77 ▼4.72
Posts /wp-admin/edit.php2,089 ▼02.02 ▼0.0238.18 ▼3.1435.17 ▲0.19
Add New Post /wp-admin/post-new.php1,533 ▼023.19 ▲0.07656.82 ▼49.3157.33 ▲6.62
Media Library /wp-admin/upload.php1,388 ▼34.25 ▼0.0795.48 ▼1.5942.31 ▲1.36

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 50% 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 0% 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
The following issues need your attention
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/currensees/vendor/nikic/php-parser/grammar/rebuildParsers.php
  • 1208× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Parse error
      syntax error, unexpected 'Telemetry' (T_STRING), expecting variable (T_VARIABLE) in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitDeprecationTriggered.php on line 25
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit\\Framework\\Exception' not found in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php:17
    • > PHP Fatal error
      Uncaught Error: Interface 'SebastianBergmann\\CodeCoverage\\Exception' not found in wp-content/plugins/currensees/vendor/phpunit/php-code-coverage/src/Exception/TestIdMissingException.php:14
    • > PHP Fatal error
      Cannot use ::class with dynamic class name in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/Logging/TestDox/NamePrettifier.php on line 171
    • > PHP Fatal error
      Cannot use ::class with dynamic class name in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php on line 127
    • > PHP Parse error
      syntax error, unexpected 'Telemetry' (T_STRING), expecting variable (T_VARIABLE) in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/Event/Events/TestRunner/EventFacadeSealed.php on line 22
    • > PHP Fatal error
      Uncaught Error: Class 'SebastianBergmann\\Type\\Type' not found in wp-content/plugins/currensees/vendor/sebastian/type/src/type/VoidType.php:12
    • > PHP Fatal error
      Uncaught Error: Interface 'PHPUnit\\Event\\Subscriber' not found in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubForIntersectionOfInterfacesCreatedSubscriber.php:17
    • > PHP Parse error
      syntax error, unexpected 'string' (T_STRING), expecting variable (T_VARIABLE) in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/TextUI/Command/Commands/ListTestsAsXmlCommand.php on line 28
    • > PHP Fatal error
      Uncaught Error: Interface 'PHPUnit\\TextUI\\Exception' not found in wp-content/plugins/currensees/vendor/phpunit/phpunit/src/TextUI/Configuration/Exception/Exception.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 Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
6 plugin tags: exchange rate, exchange, exchange rates, currency, conversion...

currensees/currensees.php Passed 13 tests

The primary PHP file in "Currensees" version 1.0 is used by WordPress to initiate all plugin functionality
53 characters long description:
A WordPress plugin for integrating with Currency API.

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected95,707 lines of code in 1,638 files:
LanguageFilesBlank linesComment linesLines of code
PHP1,50316,80332,06181,338
Markdown732,98606,751
JSON36603,970
yacc3336122,050
XSD4001,246
CSS4326133
YAML323196
JavaScript681566
XML41055
SVG2002

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Please tend to the following items
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 151)
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity5.86
▷ Minimum class complexity1.00
▷ Maximum class complexity239.00
Average method complexity2.09
▷ Minimum method complexity1.00
▷ Maximum method complexity151.00
Code structure
Namespaces130
Interfaces158
Traits9
Classes1,317
▷ Abstract classes624.71%
▷ Concrete classes1,25595.29%
▷ Final classes89471.24%
Methods6,481
▷ Static methods6069.35%
▷ Public methods5,30681.87%
▷ Protected methods4496.93%
▷ Private methods72611.20%
Functions1,568
▷ Named functions24615.69%
▷ Anonymous functions1,32284.31%
Constants547
▷ Global constants30.55%
▷ Class constants54499.45%
▷ Public constants49390.62%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin