90% camptix-pagseguro

Code Review | CampTix PagSeguro

WordPress plugin CampTix PagSeguro scored90%from 54 tests.

About plugin

  • Plugin page: camptix-pagseguro
  • Plugin version: 1.5.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4-5.5
  • WordPress version: 6.3.1
  • First release: May 11, 2013
  • Latest release: Aug 11, 2020
  • Number of updates: 20
  • Update frequency: every 132.5 days
  • Top authors: claudiosanches (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /4,961 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
Install script ran successfully

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

An overview of server-side resources used by CampTix PagSeguro
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0142.06 ▲1.30
Dashboard /wp-admin3.32 ▲0.0252.84 ▼0.58
Posts /wp-admin/edit.php3.37 ▲0.0151.76 ▲4.87
Add New Post /wp-admin/post-new.php5.90 ▲0.0186.01 ▼11.32
Media Library /wp-admin/upload.php3.25 ▲0.0136.62 ▲0.99

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for CampTix PagSeguro
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,837 ▲6614.74 ▲0.091.96 ▼0.3642.71 ▲0.40
Dashboard /wp-admin2,215 ▲395.83 ▼0.0597.66 ▼27.4240.18 ▼7.46
Posts /wp-admin/edit.php2,098 ▲92.05 ▲0.0535.06 ▼0.6331.11 ▼4.81
Add New Post /wp-admin/post-new.php1,531 ▲1223.21 ▼0.09651.63 ▼41.1357.38 ▲1.65
Media Library /wp-admin/upload.php1,394 ▲34.24 ▲0.0699.05 ▼1.1945.32 ▼0.77

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests Passed 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)
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: pagseguro, camptix

camptix-pagseguro/camptix-pagseguro.php Passed 13 tests

The main PHP script in "CampTix PagSeguro" version 1.5.5 is automatically included on every request by WordPress
29 characters long description:
PagSeguro Gateway for CampTix

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
Good job! No executable or dangerous file extensions detected270 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP389180270

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity16.00
▷ Minimum class complexity3.00
▷ Maximum class complexity29.00
Average method complexity2.76
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods15.88%
▷ Public methods1164.71%
▷ Protected methods529.41%
▷ Private methods15.88%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin