78% lbk-count-view

Code Review | LBK Size View Count

WordPress plugin LBK Size View Count scored 78% from 54 tests.

About plugin

  • Plugin page: lbk-count-view
  • Plugin version: 1.0.5
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 1.0.5-5.7
  • WordPress version: 5.9.2
  • First release: Mar 12, 2021
  • Latest release: Mar 30, 2021
  • Number of updates: 14
  • Update frequency: every 1.3 days
  • Top authors: serviceslbk (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 203 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

A check of server-side resources used by LBK Size View Count
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.1874.99 ▼2.06
Dashboard /wp-admin3.44 ▲0.0343.60 ▼6.87
Posts /wp-admin/edit.php3.66 ▲0.0249.59 ▼18.39
Add New Post /wp-admin/post-new.php6.90 ▼0.06117.38 ▼1,156.95
Media Library /wp-admin/upload.php3.31 ▲0.0238.13 ▲5.93
LBK Count View /wp-admin/options-general.php?page=lbk-count-view3.3233.10

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 12 new files
Database: 1 new table, no new options
New tables
wp_countview

Browser metrics Passed 4 tests

Checking browser requirements for LBK Size View Count
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,814 ▲6015.98 ▲0.867.44 ▼2.453.19 ▼0.98
Dashboard /wp-admin2,909 ▲226.45 ▲0.03145.36 ▼103.68175.22 ▼164.44
Posts /wp-admin/edit.php2,693 ▲23.44 ▲0.0268.88 ▼50.63163.35 ▼172.04
Add New Post /wp-admin/post-new.php1,638 ▲319.85 ▲1.06508.72 ▼24.67181.40 ▲4.37
Media Library /wp-admin/upload.php1,703 ▲85.71 ▼0.02171.34 ▼1.85221.82 ▼9.78
LBK Count View /wp-admin/options-general.php?page=lbk-count-view1,0432.5663.68131.97

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_countview

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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 fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/lbk-count-view/count-view.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/lbk-count-view/includes/admin-options-page.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 90% from 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
2 plugin tags: lbk-cv, size view count

lbk-count-view/count-view.php 77% from 13 tests

Analyzing the main PHP file in "LBK Size View Count" version 1.0.5
You should first fix the following items:
  • Domain Path: The domain path is invalid: folder "/languages/" does not exist
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: The principal plugin file should be the same as the plugin slug ("lbk-count-view.php" instead of "count-view.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin279 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP544185221
Markdown121046
CSS20012

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity4.00
▷ Minimum class complexity3.00
▷ Maximum class complexity5.00
Average method complexity1.40
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes2100.00%
Methods15
▷ Static methods640.00%
▷ Public methods1066.67%
▷ Protected methods00.00%
▷ Private methods533.33%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants480.00%
▷ Class constants120.00%
▷ Public constants1100.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