67% rnwp-app-template-config

Code Review | RNWP App template config

WordPress plugin RNWP App template config scored67%from 54 tests.

About plugin

  • Plugin page: rnwp-app-template...
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 1.0.0-5.9.3
  • WordPress version: 6.3.1
  • First release: Nov 5, 2020
  • Latest release: Apr 24, 2022
  • Number of updates: 6
  • Update frequency: every 89.2 days
  • Top authors: mkhaledche (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,914 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼1.04MB] [CPU: ▼49.29ms] Passed 4 tests

Analyzing server-side resources used by RNWP App template config
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.95 ▼0.5214.32 ▼24.94
Dashboard /wp-admin2.99 ▼0.3620.94 ▼46.30
Posts /wp-admin/edit.php2.99 ▼0.3722.18 ▼29.06
Add New Post /wp-admin/post-new.php2.99 ▼2.9020.23 ▼96.86
Media Library /wp-admin/upload.php2.99 ▼0.2419.52 ▼17.88

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for RNWP App template config
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲6613.66 ▼0.372.07 ▲0.1141.54 ▼0.06
Dashboard /wp-admin2,230 ▲235.83 ▲0.9096.96 ▼18.3239.80 ▼1.01
Posts /wp-admin/edit.php2,112 ▲151.99 ▼0.0440.88 ▲6.8435.69 ▲1.69
Add New Post /wp-admin/post-new.php1,555 ▲1623.46 ▲5.37603.57 ▼26.5846.51 ▼6.29
Media Library /wp-admin/upload.php1,412 ▲124.22 ▲0.03104.17 ▲0.9443.81 ▲0.39

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/rnwp-app-template-config/inc/appearance-settings.php+53
    Trying to access array offset on value of type bool
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/rnwp-app-template-config/rnwp.php
  • 4× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/rnwp-app-template-config/inc/rnwp-options.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/rnwp-app-template-config/inc/search-api.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/rnwp-app-template-config/inc/appearance-settings.php:21
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/rnwp-app-template-config/inc/rnwp-settings.php:17

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)
There were no browser issues found

Optimizations

Plugin configuration 86% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: android, mobile app, react native, rest api, ios

rnwp-app-template-config/rnwp.php 69% from 13 tests

The main file in "RNWP App template config" v. 1.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("rnwp-app-template-config.php" instead of "rnwp.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Domain Path: Prefix the domain path with a forward slash character ("/languages")
  • Domain Path: Use only dashes and lowercase characters for the domain path ("languages")

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
No dangerous file extensions were detected1,595 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP6234109982
JavaScript13713329
CSS294284

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity23.00
▷ Minimum class complexity23.00
▷ Maximum class complexity23.00
Average method complexity2.67
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions86
▷ Named functions8497.67%
▷ Anonymous functions22.33%
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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
css/searchicon.png0.84KB0.46KB▼ 45.23%