72% mapifylite

Code Review | MapifyLite (by MapifyPro)

WordPress plugin MapifyLite (by MapifyPro) scored72%from 54 tests.

About plugin

  • Plugin page: mapifylite
  • Plugin version: 4.3.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8.15-6.1
  • WordPress version: 6.3.1
  • First release: Apr 3, 2021
  • Latest release: Nov 29, 2022
  • Number of updates: 12
  • Update frequency: every 51.3 days
  • Top authors: mapifypro (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

300+ active /6,698 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲4.26MB] [CPU: ▲32.34ms] Passed 4 tests

Analyzing server-side resources used by MapifyLite (by MapifyPro)
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /7.65 ▲4.1971.39 ▲27.13
Dashboard /wp-admin7.52 ▲4.2175.43 ▲25.98
Posts /wp-admin/edit.php7.81 ▲4.4585.85 ▲39.61
Add New Post /wp-admin/post-new.php10.21 ▲4.32132.21 ▲36.62
Media Library /wp-admin/upload.php7.55 ▲4.3273.57 ▲40.00
Map Settings /wp-admin/edit.php?post_type=map7.2762.09
Map Locations /wp-admin/edit.php?post_type=map-location7.6661.91

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 470 new files
Database: no new tables, 9 new options
New WordPress options
acf_version
widget_recent-posts
db_upgraded
mpfy_flush_required
theysaidso_admin_options
can_compress_scripts
mpfy_plugin_version
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for MapifyLite (by MapifyPro)
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,999 ▲25313.57 ▼1.024.88 ▲3.1339.21 ▼5.30
Dashboard /wp-admin2,288 ▲974.88 ▼0.03111.61 ▼11.7252.75 ▲8.38
Posts /wp-admin/edit.php2,174 ▲852.17 ▲0.1243.08 ▲7.1746.46 ▲13.78
Add New Post /wp-admin/post-new.php6,717 ▲5,18728.90 ▲10.761,082.59 ▲462.7540.31 ▼21.59
Media Library /wp-admin/upload.php2,014 ▲6268.34 ▲4.15239.83 ▲141.9161.54 ▲19.21
Map Settings /wp-admin/edit.php?post_type=map2,8859.05213.02131.25
MapifyPro Installer /wp-admin/mapify.php?page=mapifypro-installer260.440.1314.38
Map Locations /wp-admin/edit.php?post_type=map-location1,1442.1335.1739.51

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The uninstall procedure has failed, leaving 9 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • mpfy_plugin_version
    • mpfy_flush_required
    • db_upgraded
    • acf_version
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 0% 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
The following issues need your attention
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/mapifylite/templates/popup.php
    • > /wp-content/plugins/mapifylite/templates/map.js.php
    • > /wp-content/plugins/mapifylite/lib/acf-mapifylite/public/partials/acf-mapifylite-public-display.php
  • 144× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/mapifylite/modules/map-location-popup.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/mapifylite/modules/updater.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/mapifylite/lib/advanced-custom-fields/includes/fields/class-acf-field-group.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acf_esc_attr_e() in wp-content/plugins/mapifylite/lib/acf-mapifylite/admin/partials/mapify-map-selector-field-display.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/mapifylite/lib/advanced-custom-fields/includes/api/api-template.php:928
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acf_idify() in wp-content/plugins/mapifylite/lib/advanced-custom-fields/includes/admin/views/field-group-field.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/mapifylite/lib/advanced-custom-fields/includes/fields/class-acf-field-link.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/mapifylite/modules/service-map-settings.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/mapifylite/lib/advanced-custom-fields/includes/fields/class-acf-field-output.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Image_Editor_GD' not found in wp-content/plugins/mapifylite/lib/wpthumb/wpthumb.image-editor.php:3

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There are user-side issues you should fix
    • > GET request to /wp-admin/mapify.php?page=mapifypro-installer
    • > Network (severe)
    wp-admin/mapify.php?page=mapifypro-installer - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need to be fixed:
  • Screenshots: No descriptions were found for these screenshots #1, #2, #3, #4, #5, #6 in mapifylite/assets to your readme.txt
You can look at the official readme.txt

mapifylite/mapify_lite.php 85% from 13 tests

The main PHP file in "MapifyLite (by MapifyPro)" ver. 4.3.4 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("mapifylite.php" instead of "mapify_lite.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin123,336 lines of code in 328 files:
LanguageFilesBlank linesComment linesLines of code
PO File3223,72640,12349,150
JavaScript449,5747,72636,518
PHP21012,17421,86621,417
SVG111011,620
CSS257662324,174
Sass2275262
LESS1115152
JSON10021
Markdown111014
Ruby1208

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity12.42
▷ Minimum class complexity1.00
▷ Maximum class complexity78.00
Average method complexity2.60
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes134
▷ Abstract classes32.24%
▷ Concrete classes13197.76%
▷ Final classes00.00%
Methods962
▷ Static methods131.35%
▷ Public methods93196.78%
▷ Protected methods10.10%
▷ Private methods303.12%
Functions539
▷ Named functions53899.81%
▷ Anonymous functions10.19%
Constants28
▷ Global constants2796.43%
▷ Class constants13.57%
▷ Public constants1100.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
52 PNG files occupy 0.24MB with 0.15MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/zoom-out.png0.99KB0.12KB▼ 87.71%
assets/images/arrow.png1.31KB0.25KB▼ 80.61%
lib/advanced-custom-fields/assets/images/acf-logo.png3.40KB3.39KB0.23%
assets/images/mpfy-p-sprite.png35.91KB13.52KB▼ 62.35%
assets/images/ico-search.png3.11KB0.49KB▼ 84.14%