84% mapp-intelligence

Code Review | Mapp Intelligence

WordPress plugin Mapp Intelligence scored84%from 54 tests.

About plugin

  • Plugin page: mapp-intelligence
  • Plugin version: 1.1.9
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Mar 30, 2020
  • Latest release: Feb 16, 2023
  • Number of updates: 19
  • Update frequency: every 55.6 days
  • Top authors: mappdigital (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,448 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.27MB] [CPU: ▼6.87ms] Passed 4 tests

An overview of server-side resources used by Mapp Intelligence
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.78 ▲0.3237.08 ▼5.94
Dashboard /wp-admin3.61 ▲0.2753.02 ▼9.14
Posts /wp-admin/edit.php3.66 ▲0.3151.84 ▲5.68
Add New Post /wp-admin/post-new.php6.15 ▲0.2788.59 ▼13.51
Media Library /wp-admin/upload.php3.47 ▲0.2436.32 ▲1.11
Mapp Cloud /wp-admin/plugins.php?page=mapp-intelligence3.5432.06

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Mapp Intelligence
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲4114.38 ▲0.113.57 ▲1.8140.86 ▼2.96
Dashboard /wp-admin2,202 ▲255.50 ▼0.0781.18 ▼7.8537.38 ▼6.58
Posts /wp-admin/edit.php2,107 ▲102.04 ▲0.0334.92 ▲0.9833.38 ▼1.89
Add New Post /wp-admin/post-new.php1,532 ▲623.64 ▲0.07623.25 ▼67.6251.46 ▼1.42
Media Library /wp-admin/upload.php1,407 ▲44.24 ▲0.0392.96 ▼9.1740.61 ▼3.32
Mapp Cloud /wp-admin/plugins.php?page=mapp-intelligence9021.8628.4923.17

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Trait 'MappCloud\\Intelligence\\DataLayer\\Page' not found in wp-content/plugins/mapp-intelligence/src/Intelligence/DataLayer/DataLayer.php on line 10

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 93% from 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
3 plugin tags: tracking, marketing, analytics

mapp-intelligence/mapp_intelligence.php 85% from 13 tests

The main file in "Mapp Intelligence" v. 1.1.9 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: The principal plugin file should be the same as the plugin slug ("mapp-intelligence.php" instead of "mapp_intelligence.php")
  • Description: Please keep the plugin description shorter than 140 characters (currently 159 characters long)

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 detected2,269 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
PHP212153981,790
JavaScript300357
PO File12729109
HTML11012
JSON1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity14.13
▷ Minimum class complexity1.00
▷ Maximum class complexity88.00
Average method complexity3.49
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces6
Interfaces0
Traits3
Classes12
▷ Abstract classes00.00%
▷ Concrete classes12100.00%
▷ Final classes00.00%
Methods80
▷ Static methods1822.50%
▷ Public methods7188.75%
▷ Protected methods00.00%
▷ Private methods911.25%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.00%
Constants0
▷ Global constants00.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
No PNG files were detected