84% anomify

Code Review | Anomify AI - Anomaly Detection and Alerting

WordPress plugin Anomify AI - Anomaly Detection and Alerting scored84%from 54 tests.

About plugin

  • Plugin page: anomify
  • Plugin version: 0.3.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.2.3
  • WordPress version: 6.3.1
  • First release: Jul 15, 2022
  • Latest release: Jul 12, 2023
  • Number of updates: 21
  • Update frequency: every 17.2 days
  • Top authors: simon.holliday (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /773 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

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

A check of server-side resources used by Anomify AI - Anomaly Detection and Alerting
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.06 ▼3.04
Dashboard /wp-admin3.31 ▲0.0149.90 ▼1.15
Posts /wp-admin/edit.php3.36 ▲0.0148.39 ▼2.36
Add New Post /wp-admin/post-new.php5.89 ▲0.0188.07 ▼14.37
Media Library /wp-admin/upload.php3.23 ▲0.0140.81 ▲0.38
Anomify /wp-admin/options-general.php?page=anomify3.2531.99

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Anomify AI - Anomaly Detection and Alerting
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.38 ▲0.001.82 ▲0.1143.09 ▼1.24
Dashboard /wp-admin2,199 ▲225.66 ▲0.0594.67 ▲0.9042.23 ▼2.97
Posts /wp-admin/edit.php2,104 ▲12.02 ▲0.0337.36 ▼5.5734.74 ▼0.39
Add New Post /wp-admin/post-new.php1,548 ▲1623.28 ▲0.32665.10 ▼8.3065.39 ▲7.68
Media Library /wp-admin/upload.php1,407 ▲74.24 ▲0.00114.51 ▲9.0350.66 ▲5.54
Anomify /wp-admin/options-general.php?page=anomify9282.0123.2023.86

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
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'Anomify_Config' not found in wp-content/plugins/anomify/Anomify/Wp/includes/admin_options.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_uninstall_hook() in wp-content/plugins/anomify/index.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 96% from 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
7 plugin tags: analytics, detection, metrics, anomalies, analysis...

anomify/index.php 92% from 13 tests

"Anomify AI - Anomaly Detection and Alerting" version 0.3.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("anomify.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin732 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP934590732

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity14.43
▷ Minimum class complexity1.00
▷ Maximum class complexity33.00
Average method complexity2.34
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods70
▷ Static methods5274.29%
▷ Public methods5578.57%
▷ Protected methods00.00%
▷ Private methods1521.43%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants12
▷ Global constants216.67%
▷ Class constants1083.33%
▷ Public constants10100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected