84% qqworld-content-provider

Code Review | QQWorld Content Provider

WordPress plugin QQWorld Content Provider scored84%from 54 tests.

About plugin

  • Plugin page: qqworld-content-p...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.0.1
  • WordPress version: 6.3.1
  • First release: Mar 25, 2015
  • Latest release: Mar 25, 2015
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: qqworld (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /592 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.60ms] Passed 4 tests

This is a short check of server-side resources used by QQWorld Content Provider
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.85 ▲0.76
Dashboard /wp-admin3.31 ▲0.0143.33 ▼7.99
Posts /wp-admin/edit.php3.36 ▲0.0143.26 ▼1.99
Add New Post /wp-admin/post-new.php5.89 ▲0.0188.01 ▼6.39
Media Library /wp-admin/upload.php3.23 ▲0.0132.73 ▼2.04

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

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

Browser metrics Passed 4 tests

Checking browser requirements for QQWorld Content Provider
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.29 ▼1.101.65 ▼0.0739.51 ▼0.96
Dashboard /wp-admin2,206 ▲184.84 ▼0.03109.31 ▲0.2040.11 ▼0.70
Posts /wp-admin/edit.php2,089 ▼02.06 ▼0.0139.41 ▲3.1034.22 ▲0.38
Add New Post /wp-admin/post-new.php1,536 ▲1723.42 ▲0.21670.72 ▲38.5350.25 ▼4.74
Media Library /wp-admin/upload.php1,388 ▼34.23 ▲0.0893.63 ▼4.4440.67 ▼3.65

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/qqworld-content-provider/qqworld-content-provider.php:13

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: provider, content, app, mobile

qqworld-content-provider/qqworld-content-provider.php Passed 13 tests

The main PHP script in "QQWorld Content Provider" version 1.0 is automatically included on every request by WordPress
21 characters long description:
Using for Mobile APP.

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 plugin133 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1913107
PO File13326

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.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
PNG images were not found in this plugin