79% comscore-tag

Code Review | Comscore tag

WordPress plugin Comscore tag scored79%from 54 tests.

About plugin

  • Plugin page: comscore-tag
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-4.6
  • WordPress version: 6.3.1
  • First release: Jun 28, 2013
  • Latest release: Aug 17, 2016
  • Number of updates: 7
  • Update frequency: every 163.7 days
  • Top authors: marcocanestrari (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /2,441 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.02MB] [CPU: ▼3.35ms] Passed 4 tests

An overview of server-side resources used by Comscore tag
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.39 ▼0.0725.33 ▼18.36
Dashboard /wp-admin3.31 ▲0.0146.01 ▼0.63
Posts /wp-admin/edit.php3.36 ▲0.0051.00 ▲1.56
Add New Post /wp-admin/post-new.php5.89 ▲0.0089.96 ▲4.05
Media Library /wp-admin/upload.php3.23 ▲0.0041.09 ▲9.29
Comscore /wp-admin/options-general.php?page=comscore-tag3.1737.62

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Comscore tag
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6914.48 ▲0.091.66 ▼0.1038.00 ▼8.58
Dashboard /wp-admin2,213 ▲285.86 ▲0.96106.79 ▲3.0743.66 ▼0.66
Posts /wp-admin/edit.php2,096 ▲42.06 ▲0.0540.35 ▼0.6735.64 ▼2.49
Add New Post /wp-admin/post-new.php1,545 ▲318.39 ▲0.12677.07 ▲41.0054.48 ▼8.32
Media Library /wp-admin/upload.php1,392 ▲44.13 ▼0.04109.40 ▲13.7146.17 ▲1.34
Comscore /wp-admin/options-general.php?page=comscore-tag8062.0524.1925.64

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
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=comscore-tag
    • > Notice in wp-content/plugins/comscore-tag/comscore-tag.php+64
    Undefined index: comscore_settings
    • > GET request to /wp-admin/options-general.php?page=comscore-tag
    • > Warning in wp-content/plugins/comscore-tag/comscore-tag.php+88
    Use of undefined constant C2 - assumed 'C2' (this will throw an Error in a future version of PHP)
    • > GET request to /wp-admin/options-general.php?page=comscore-tag
    • > Notice in wp-content/plugins/comscore-tag/comscore-tag.php+88
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/comscore-tag/comscore-tag.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: comscore, tracking, visits, pageviews, visitors...

comscore-tag/comscore-tag.php Passed 13 tests

The entry point to "Comscore tag" version 1.0 is a PHP file that has certain tags in its header comment area
39 characters long description:
Add Comscore tracking tag to your pages

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
Success! There were no dangerous files found in this plugin89 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1392589

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.31
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

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