68% no-chinese-simplified-visit

Code Review | No Chinese Simplified Visit

WordPress plugin No Chinese Simplified Visit scored 68% from 54 tests.

About plugin

  • Plugin page: no-chinese-simpli...
  • Plugin version: 1.1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.8
  • WordPress version: 6.3.1
  • First release: Feb 15, 2014
  • Latest release: Mar 5, 2014
  • Number of updates: 27
  • Update frequency: every 0.7 days
  • Top authors: eflyjason (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 897 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▼1.24MB] [CPU: ▼41.86ms] Passed 4 tests

A check of server-side resources used by No Chinese Simplified Visit
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.73 ▼0.7314.02 ▼30.58
Dashboard /wp-admin2.77 ▼0.5415.86 ▼33.49
Posts /wp-admin/edit.php2.77 ▼0.5915.85 ▼34.25
Add New Post /wp-admin/post-new.php2.77 ▼3.1216.31 ▼69.13
Media Library /wp-admin/upload.php2.77 ▼0.4614.85 ▼19.43
No Chinese Simplified Visit /wp-admin/options-general.php?page=no-chinese-simplified-visit-options2.7715.28

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
db_upgraded
theysaidso_admin_options
no_chinese_simplified_visit_notice
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for No Chinese Simplified Visit
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲4713.19 ▼1.192.06 ▼0.0954.71 ▲8.08
Dashboard /wp-admin2,210 ▲224.88 ▼0.22107.81 ▼6.5440.77 ▼2.30
Posts /wp-admin/edit.php2,093 ▲42.05 ▲0.0539.72 ▲5.9735.25 ▲0.20
Add New Post /wp-admin/post-new.php1,526 ▲1223.15 ▲5.69660.18 ▼10.6366.06 ▲13.34
Media Library /wp-admin/upload.php1,395 ▲74.18 ▼0.0197.74 ▼8.4245.04 ▲0.14
No Chinese Simplified Visit /wp-admin/options-general.php?page=no-chinese-simplified-visit-options1,4996.76168.55110.83

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin did not uninstall without warnings or errors
    • > Notice in wp-content/plugins/no-chinese-simplified-visit/no-chinese-simplified-visit.php+54
    Undefined index: HTTP_ACCEPT_LANGUAGE
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • no_chinese_simplified_visit_notice
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=no-chinese-simplified-visit-options
    • > Notice in wp-content/plugins/no-chinese-simplified-visit/no-chinese-simplified-visit.php+54
    Undefined index: HTTP_ACCEPT_LANGUAGE

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 2× 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/no-chinese-simplified-visit/options.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/no-chinese-simplified-visit/no-chinese-simplified-visit.php:34

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
2 plugin tags: no spam, visitor

no-chinese-simplified-visit/no-chinese-simplified-visit.php Passed 13 tests

The main PHP script in "No Chinese Simplified Visit" version 1.1.2 is automatically included on every request by WordPress
99 characters long description:
Disallow Chinese Simplified Visitors in Your Blog. 在你的部落格中禁止簡體中文的訪客

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin111 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP2152557
PO File2122254

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.12
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%
Constants3
▷ Global constants3100.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
There were not PNG files found in your plugin