84% pageview

Code Review | PageView

WordPress plugin PageView scored84%from 54 tests.

About plugin

  • Plugin page: pageview
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 2.5-4.1
  • WordPress version: 6.3.1
  • First release: Sep 26, 2006
  • Latest release: Sep 7, 2014
  • Number of updates: 22
  • Update frequency: every 132.0 days
  • Top authors: johnny5 (100%)matt (9.09%)

Code review

54 tests

User reviews

5 reviews

Install metrics

1,000+ active /70,075 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

A check of server-side resources used by PageView
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0038.11 ▼1.10
Dashboard /wp-admin3.31 ▲0.0050.27 ▼3.45
Posts /wp-admin/edit.php3.36 ▲0.0050.80 ▼2.31
Add New Post /wp-admin/post-new.php5.89 ▲0.0088.88 ▼9.69
Media Library /wp-admin/upload.php3.23 ▲0.0036.17 ▼3.35

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for PageView
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.63 ▲0.251.63 ▼0.1841.98 ▼2.24
Dashboard /wp-admin2,195 ▲175.60 ▼0.1380.63 ▼20.0241.90 ▼2.11
Posts /wp-admin/edit.php2,100 ▼32.00 ▼0.0134.07 ▼5.5934.19 ▼7.04
Add New Post /wp-admin/post-new.php1,545 ▲1923.56 ▲5.80691.35 ▲3.4459.65 ▲0.63
Media Library /wp-admin/upload.php1,400 ▼04.21 ▼0.03109.87 ▲6.6146.42 ▲1.81

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
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however 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
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pageview/pageview.php:95

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 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
5 plugin tags: page, iframe, html, embed, post

pageview/pageview.php 92% from 13 tests

"PageView" version 1.6'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:
  • Description: Keep the plugin description shorter than 140 characters (currently 193 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected67 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1191067

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity13.00
▷ Minimum class complexity13.00
▷ Maximum class complexity13.00
Average method complexity5.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods266.67%
▷ Protected methods00.00%
▷ Private methods133.33%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected