84% xml-for-google-merchant-center

Code Review | XML for Google Merchant Center

WordPress plugin XML for Google Merchant Center scored84%from 54 tests.

About plugin

  • Plugin page: xml-for-google-me...
  • Plugin version: 3.0.8
  • PHP compatiblity: 7.0.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.4.1
  • WordPress version: 6.3.1
  • First release: Jun 20, 2019
  • Latest release: Nov 28, 2023
  • Number of updates: 114
  • Update frequency: every 14.2 days
  • Top authors: icopydoc (100%)

Code review

54 tests

User reviews

13 reviews

Install metrics

4,000+ active /99,348 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

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

Analyzing server-side resources used by XML for Google Merchant Center
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0138.63 ▼2.66
Dashboard /wp-admin3.31 ▼0.0350.24 ▼10.41
Posts /wp-admin/edit.php3.36 ▲0.0149.24 ▲4.46
Add New Post /wp-admin/post-new.php5.89 ▲0.0186.59 ▼3.17
Media Library /wp-admin/upload.php3.24 ▲0.0134.02 ▼8.17

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 57 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by XML for Google Merchant Center
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲4814.25 ▲0.021.72 ▼0.0730.01 ▼14.42
Dashboard /wp-admin2,197 ▲195.52 ▼0.1993.19 ▼22.2645.06 ▲1.83
Posts /wp-admin/edit.php2,105 ▲51.94 ▼0.0537.61 ▲3.0737.47 ▲2.39
Add New Post /wp-admin/post-new.php1,531 ▲523.39 ▲0.26663.39 ▲40.9458.76 ▲11.09
Media Library /wp-admin/upload.php1,402 ▼14.17 ▲0.07101.84 ▲1.0942.95 ▲1.54

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_List_Table' not found in wp-content/plugins/xml-for-google-merchant-center/classes/system/class-xfgmc-wp-list-table.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_List_Table' not found in wp-content/plugins/xml-for-google-merchant-center/classes/system/class-xfgmc-settings-feed-wp-list-table.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Screenshots: Screenshot #1 (screenshot-2.png) image not found
You can look at the official readme.txt

xml-for-google-merchant-center/xml-for-google-merchant-center.php Passed 13 tests

The main file in "XML for Google Merchant Center" v. 3.0.8 serves as a complement to information provided in readme.txt and as the entry point to the plugin
88 characters long description:
Connect your store to Google Merchant Center and unload products, getting new customers!

Code Analysis Passed 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
There were no executable files found in this plugin10,851 lines of code in 43 files:
LanguageFilesBlank linesComment linesLines of code
PHP419621,8929,402
PO File17951,3241,419
CSS10030

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity9.05
▷ Minimum class complexity1.00
▷ Maximum class complexity74.00
Average method complexity3.85
▷ Minimum method complexity1.00
▷ Maximum method complexity44.00
Code structure
Namespaces0
Interfaces0
Traits78
Classes24
▷ Abstract classes14.17%
▷ Concrete classes2395.83%
▷ Final classes730.43%
Methods289
▷ Static methods165.54%
▷ Public methods21975.78%
▷ Protected methods175.88%
▷ Private methods5318.34%
Functions65
▷ Named functions5381.54%
▷ Anonymous functions1218.46%
Constants21
▷ Global constants1780.95%
▷ Class constants419.05%
▷ Public constants4100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.20MB with 0.13MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png110.57KB42.10KB▼ 61.92%
screenshot-1.png97.42KB36.47KB▼ 62.56%