79% property-drive

Code Review | Property Drive

WordPress plugin Property Drive scored79%from 54 tests.

About plugin

  • Plugin page: property-drive
  • Plugin version: 1.1.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.3
  • WordPress version: 6.3.1
  • First release: May 8, 2017
  • Latest release: Jul 26, 2023
  • Number of updates: 180
  • Update frequency: every 12.6 days
  • Top authors: jaythegeek (92.22%)butterflymedia (4.44%)propertydrive (4.44%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,180 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.84MB] [CPU: ▼0.23ms] Passed 4 tests

An overview of server-side resources used by Property Drive
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.38 ▲0.8746.82 ▼0.31
Dashboard /wp-admin4.20 ▲0.8253.39 ▼10.50
Posts /wp-admin/edit.php4.26 ▲0.8658.40 ▲1.06
Add New Post /wp-admin/post-new.php6.80 ▲0.87115.24 ▲13.18
Media Library /wp-admin/upload.php4.06 ▲0.7941.13 ▲8.82
All Properties /wp-admin/edit.php?post_type=property4.1143.39
Area /wp-admin/edit-tags.php?taxonomy=property_area&post_type=property4.0640.67
County /wp-admin/edit-tags.php?taxonomy=property_county&post_type=property4.0640.16
Add New /wp-admin/post-new.php?post_type=property4.2957.24
Types /wp-admin/edit-tags.php?taxonomy=property_type&post_type=property4.0650.50

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 62 new files
Database: no new tables, 36 new options
New WordPress options
allow_favourites
db_upgraded
show_property_card_description
search_field_status
search_field_baths
allow_quick_contact
search_field_multitype
agency_phone
search_field_price
cinematic_overlay
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for Property Drive
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,936 ▲17516.06 ▲1.714.76 ▲3.0341.26 ▼5.68
Dashboard /wp-admin2,294 ▲1177.15 ▲1.49111.40 ▲10.9143.71 ▲2.07
Posts /wp-admin/edit.php2,201 ▲1014.42 ▲2.3850.64 ▲13.9637.56 ▲2.52
Add New Post /wp-admin/post-new.php6,325 ▲4,79923.23 ▲0.10948.81 ▲308.4837.51 ▼13.72
Media Library /wp-admin/upload.php1,499 ▲996.79 ▲2.60107.45 ▲8.3840.17 ▼5.56
All Properties /wp-admin/edit.php?post_type=property1,2044.3745.0129.40
Area /wp-admin/edit-tags.php?taxonomy=property_area&post_type=property1,3784.1739.1629.26
County /wp-admin/edit-tags.php?taxonomy=property_county&post_type=property1,3783.7436.1928.91
Add New /wp-admin/post-new.php?post_type=property3,1399.57188.9675.84
Types /wp-admin/edit-tags.php?taxonomy=property_type&post_type=property1,3844.1737.9428.45

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
The following items require your attention
  • The uninstall procedure has failed, leaving 36 options in the database
    • search_field_group
    • search_field_baths
    • search_field_location
    • search_field_type
    • show_related_properties
    • can_compress_scripts
    • osm_scrollzoom
    • ribbon_colour_sale_agreed
    • google_maps_api_key
    • search_field_status
    • ...

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=property
    • > Notice in wp-content/plugins/property-drive/includes/helpers.php+1322
    Undefined variable: post_id

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
The following issues need your attention
  • 19× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/property-drive/includes/admin/build_admin_page.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/property-drive/modules/user_sign_up.php:79
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/property-drive/modules/user_sign_up.php:79
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/property-drive/includes/inline_styling.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/property-drive/modules/cpt-emails.php:60
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/property-drive/modules/user_dashboard.php:311
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/property-drive/property-drive.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/property-drive/includes/property_search.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/property-drive/templates/single-property.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/property-drive/shortcodes/property-grid.php:401

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

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
5 plugin tags: real estate, estate agents, house, home, property

property-drive/property-drive.php Passed 13 tests

Analyzing the main PHP file in "Property Drive" version 1.1.1
96 characters long description:
Property management system for WordPress. Add properties, search, display, filter, sort and map.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin27,605 lines of code in 42 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript145,9387,47419,010
PHP208774804,726
CSS85851863,869

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.40
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%
Functions107
▷ Named functions10699.07%
▷ Anonymous functions10.93%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
14 PNG files occupy 0.05MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/js/leaflet/images/layers.png0.68KB1.05KB0.00%
assets/images/fullscreen@2x.png0.15KB0.15KB0.00%
assets/images/map-marker-red.png2.12KB0.94KB▼ 55.68%
assets/js/leaflet/images/marker-shadow.png0.60KB1.16KB0.00%
assets/images/foursquare.png2.11KB0.69KB▼ 67.10%