78% simple-staff-list

Code Review | Simple Staff List

WordPress plugin Simple Staff List scored78%from 54 tests.

About plugin

  • Plugin page: simple-staff-list
  • Plugin version: 2.2.5
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.3.2
  • WordPress version: 6.3.1
  • First release: Jan 7, 2013
  • Latest release: Oct 31, 2023
  • Number of updates: 71
  • Update frequency: every 55.6 days
  • Top authors: brettshumaker (100%)

Code review

54 tests

User reviews

40 reviews

Install metrics

5,000+ active /139,439 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.24MB] [CPU: ▼4.87ms] Passed 4 tests

This is a short check of server-side resources used by Simple Staff List
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.72 ▲0.2551.12 ▲5.17
Dashboard /wp-admin3.55 ▲0.2444.94 ▼6.03
Posts /wp-admin/edit.php3.66 ▲0.3051.79 ▼3.62
Add New Post /wp-admin/post-new.php6.13 ▲0.2482.95 ▼12.76
Media Library /wp-admin/upload.php3.47 ▲0.2338.52 ▲2.92
Groups /wp-admin/edit-tags.php?taxonomy=staff-member-group&post_type=staff-member3.5836.82
Options /wp-admin/edit.php?post_type=staff-member&page=staff-member-options3.4633.65
Usage /wp-admin/edit.php?post_type=staff-member&page=staff-member-usage3.4431.17
Templates /wp-admin/edit.php?post_type=staff-member&page=staff-member-template3.4835.81
Add New /wp-admin/post-new.php?post_type=staff-member3.6752.79
All Staff Members /wp-admin/edit.php?post_type=staff-member3.5138.42
Order /wp-admin/edit.php?post_type=staff-member&page=staff-member-order3.4533.82
Export /wp-admin/edit.php?post_type=staff-member&page=staff-member-export3.4534.28

Server storage [IO: ▲0.27MB] [DB: ▲0.01MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
It is recommended to fix the following issues
  • There were 1 file (1.19KB) illegally modified outside of "wp-content/plugins/simple-staff-list/" and "wp-content/uploads/"
    • (new file) wp-content/themes/twentytwentyone/simple-staff-list-custom.css
Filesystem: 57 new files
Database: no new tables, 20 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
_staff_listing_default_name_singular
widget_recent-comments
_staff_listing_default_formatted_tags
_staff_listing_default_tag_string
_staff_listing_default_slug
_staff_listing_default_css
db_upgraded
_staff_listing_custom_slug
...

Browser metrics Passed 4 tests

Checking browser requirements for Simple Staff List
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,873 ▲8714.36 ▼0.351.73 ▼0.3642.73 ▼2.57
Dashboard /wp-admin2,277 ▲1005.64 ▼0.0390.14 ▼7.3139.30 ▼8.53
Posts /wp-admin/edit.php2,179 ▲791.99 ▼0.0139.92 ▲2.7938.09 ▲3.41
Add New Post /wp-admin/post-new.php1,577 ▲4922.77 ▼0.44686.98 ▲36.3855.86 ▼16.05
Media Library /wp-admin/upload.php1,490 ▲964.26 ▲0.07106.45 ▲10.3947.54 ▲5.33
Groups /wp-admin/edit-tags.php?taxonomy=staff-member-group&post_type=staff-member1,3502.1226.9329.95
Options /wp-admin/edit.php?post_type=staff-member&page=staff-member-options9131.8733.5127.09
Usage /wp-admin/edit.php?post_type=staff-member&page=staff-member-usage9462.0332.4532.48
Templates /wp-admin/edit.php?post_type=staff-member&page=staff-member-template1,0221.8823.9430.50
Add New /wp-admin/post-new.php?post_type=staff-member2,4277.36159.4871.21
All Staff Members /wp-admin/edit.php?post_type=staff-member1,1722.1531.1628.50
Order /wp-admin/edit.php?post_type=staff-member&page=staff-member-order8551.7824.4926.54
Export /wp-admin/edit.php?post_type=staff-member&page=staff-member-export9011.7824.3224.05

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

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
Please take a closer look at the following
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-admin-display.php
    • > /wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-admin-sidebar.php
    • > /wp-content/plugins/simple-staff-list/public/partials/simple-staff-list-public-display.php
  • 10× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-staff-list/includes/sslp-template-hooks.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-order-display.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-template-display.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-export-display.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/simple-staff-list/public/templates/single-staff-member/staff-bio.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/simple-staff-list/public/templates/single-staff-member/staff-email.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-options-display.php:15
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/simple-staff-list/public/partials/simple-staff-list-shortcode-display.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/simple-staff-list/admin/partials/simple-staff-list-usage-display.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/simple-staff-list/includes/sslp-core-functions.php:69

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: staff directory, employee, employees, staff list, employee list...

simple-staff-list/simple-staff-list.php Passed 13 tests

Analyzing the main PHP file in "Simple Staff List" version 2.2.5
70 characters long description:
A simple plugin to build and display a staff listing for your website.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected2,340 lines of code in 47 files:
LanguageFilesBlank linesComment linesLines of code
PHP364911,1731,516
PO File2148153519
CSS24517182
JavaScript119470
SVG60253

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity11.71
▷ Minimum class complexity1.00
▷ Maximum class complexity61.00
Average method complexity2.53
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods49
▷ Static methods24.08%
▷ Public methods4489.80%
▷ Protected methods00.00%
▷ Private methods510.20%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
4 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/img/staff-list-icon.png0.82KB0.47KB▼ 42.29%
admin/img/buytickets_Ticket.png19.73KB8.57KB▼ 56.55%
admin/img/move-icon.png1.26KB0.28KB▼ 77.54%
admin/img/staff-list-icon-lighter.png0.79KB0.47KB▼ 40.59%