72% campsite-reports

Code Review | Campsite Reports OFFICIAL Wordpress Plugin

WordPress plugin Campsite Reports OFFICIAL Wordpress Plugin scored72%from 54 tests.

About plugin

  • Plugin page: campsite-reports
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.2.1
  • WordPress version: 6.3.1
  • First release: May 3, 2015
  • Latest release: Dec 18, 2015
  • Number of updates: 10
  • Update frequency: every 23.0 days
  • Top authors: campsitereports (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /803 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼7.95ms] Passed 4 tests

Server-side resources used by Campsite Reports OFFICIAL Wordpress Plugin
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0140.56 ▼6.39
Dashboard /wp-admin3.33 ▲0.0249.93 ▼5.98
Posts /wp-admin/edit.php3.38 ▲0.0245.99 ▼5.02
Add New Post /wp-admin/post-new.php5.91 ▲0.0286.90 ▼14.41
Media Library /wp-admin/upload.php3.25 ▲0.0236.56 ▼3.47
CSR Settings /wp-admin/admin.php?page=csr_wp_plugin3.2231.17
Instructions /wp-admin/admin.php?page=csr_wp_plugin_howto3.2232.78

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Campsite Reports OFFICIAL Wordpress Plugin
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲8013.21 ▼0.825.19 ▲3.1243.89 ▲3.85
Dashboard /wp-admin2,219 ▲314.90 ▼0.18105.69 ▼7.4688.39 ▲39.48
Posts /wp-admin/edit.php2,115 ▲231.99 ▼0.0337.30 ▼11.0234.59 ▼7.20
Add New Post /wp-admin/post-new.php1,689 ▲17022.25 ▼1.08679.52 ▼36.6747.73 ▼10.46
Media Library /wp-admin/upload.php1,414 ▲264.24 ▲0.03117.83 ▼12.8651.94 ▲1.64
CSR Settings /wp-admin/admin.php?page=csr_wp_plugin8412.0426.4633.38
Instructions /wp-admin/admin.php?page=csr_wp_plugin_howto9772.0128.4031.88

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Smoke test failed, please fix the following
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=csr_wp_plugin_howto
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+204
    Undefined offset: 0
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=csr_wp_plugin_howto
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+205
    Trying to get property 'guid' of non-object
  • 18 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=csr_wp_plugin_howto
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+221
    Trying to get property 'ID' of non-object
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=csr_wp_plugin_howto
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+222
    Trying to get property 'post_title' of non-object

SRP 0% 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
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/campsite-reports/csr.php
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/campsite-reports/pages/admin/main.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/campsite-reports/pages/admin/instructions.php:1

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === campsite-reports === )
The official readme.txt is a good inspiration

campsite-reports/csr.php 92% from 13 tests

"Campsite Reports OFFICIAL Wordpress Plugin" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("campsite-reports.php" instead of "csr.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
No dangerous file extensions were detected143 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP33726134
CSS2109

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.12
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%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/csr_icon_20x20.png1.65KB0.87KB▼ 47.43%