84% aliens-sci

Code Review | Custom fields to api

WordPress plugin Custom fields to api scored84%from 54 tests.

About plugin

  • Plugin page: aliens-sci
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 1.0.1-4.6.1
  • WordPress version: 6.3.1
  • First release: Oct 29, 2016
  • Latest release: Nov 1, 2016
  • Number of updates: 13
  • Update frequency: every 0.3 days
  • Top authors: 4samy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /661 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▼0.64MB] [CPU: ▼16.47ms] Passed 4 tests

Server-side resources used by Custom fields to api
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0437.54 ▼2.84
Dashboard /wp-admin3.34 ▲0.0445.14 ▼5.27
Posts /wp-admin/edit.php3.46 ▲0.1045.55 ▼3.76
Add New Post /wp-admin/post-new.php3.22 ▼2.6634.82 ▼54.02
Media Library /wp-admin/upload.php3.27 ▲0.0441.59 ▲8.42

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
recovery_mode_email_last_sent
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Custom fields to api
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.81 ▲0.261.75 ▼0.1243.37 ▼5.85
Dashboard /wp-admin2,206 ▲185.85 ▼0.05100.06 ▼17.0340.80 ▼3.21
Posts /wp-admin/edit.php2,092 ▲32.03 ▲0.0238.97 ▲0.3335.35 ▲1.40
Add New Post /wp-admin/post-new.php45 ▼1,4690.44 ▼17.120.08 ▼647.4310.05 ▼41.96
Media Library /wp-admin/upload.php1,388 ▼04.29 ▲0.1296.13 ▼1.6869.17 ▲25.69

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • recovery_mode_email_last_sent

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

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 take a closer look at the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_URL - assumed 'WP_PLUGIN_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/aliens-sci/aliens-sci.php on line 36
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/aliens-sci/aliens-sci.php on line 35
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/aliens-sci/aliens-sci.php:36

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
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 describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
2 plugin tags: api, custom fields

aliens-sci/aliens-sci.php Passed 13 tests

"Custom fields to api" version 1.0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
40 characters long description:
Puts all code from Custom fields to api.

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
Success! There were no dangerous files found in this plugin276 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP16025217
Markdown219035
PO File15724

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity17.00
▷ Minimum class complexity17.00
▷ Maximum class complexity17.00
Average method complexity1.64
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods25
▷ Static methods00.00%
▷ Public methods1872.00%
▷ Protected methods00.00%
▷ Private methods728.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin