84% my-askai

Code Review | My AskAI

WordPress plugin My AskAI scored84%from 54 tests.

About plugin

  • Plugin page: my-askai
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.2
  • WordPress version: 6.3.1
  • First release: Jun 18, 2023
  • Latest release: Jun 18, 2023
  • Number of updates: 2
  • Update frequency: every 6.0 days
  • Top authors: myaskai (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /236 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.01MB] [CPU: ▼4.96ms] Passed 4 tests

This is a short check of server-side resources used by My AskAI
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.09 ▼0.57
Dashboard /wp-admin3.31 ▲0.0148.78 ▼5.51
Posts /wp-admin/edit.php3.36 ▲0.0154.95 ▲2.97
Add New Post /wp-admin/post-new.php5.89 ▲0.0089.25 ▼16.71
Media Library /wp-admin/upload.php3.24 ▲0.0138.87 ▲5.65

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for My AskAI
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.17 ▼0.061.65 ▲0.1845.28 ▲5.10
Dashboard /wp-admin2,195 ▲145.62 ▼0.1086.49 ▼21.0439.95 ▼3.33
Posts /wp-admin/edit.php2,100 ▼01.94 ▼0.0436.02 ▼5.4634.63 ▼6.90
Add New Post /wp-admin/post-new.php1,653 ▲11724.32 ▲5.91571.19 ▼97.5554.91 ▼11.37
Media Library /wp-admin/upload.php1,400 ▼04.24 ▲0.05104.28 ▼6.2343.60 ▼1.17

Uninstaller [IO: ▲0.00MB] [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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means 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
Please fix the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/my-askai/myaskai.php:28

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: myaskai, artificial intelligence, ai, chatgpt, openai

my-askai/myaskai.php 92% from 13 tests

This is the main PHP file of "My AskAI" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("my-askai.php" instead of "myaskai.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
There were no executable files found in this plugin94 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript18147
CSS17028
PHP192819

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.14
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%
Functions2
▷ Named functions2100.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 are no PNG files in this plugin