84% staff-list

Code Review | Staff List

WordPress plugin Staff List scored84%from 54 tests.

About plugin

  • Plugin page: staff-list
  • Plugin version: 1.7.3
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.4
  • WordPress version: 6.3.1
  • First release: Feb 29, 2016
  • Latest release: Oct 27, 2023
  • Number of updates: 268
  • Update frequency: every 10.4 days
  • Top authors: abcfolio (100%)

Code review

54 tests

User reviews

22 reviews

Install metrics

4,000+ active /188,484 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
Install script ran successfully

Server metrics [RAM: ▲4.02MB] [CPU: ▲24.41ms] Passed 4 tests

An overview of server-side resources used by Staff List
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /5.36 ▲1.8953.45 ▲13.99
Dashboard /wp-admin8.03 ▲4.7278.87 ▲30.33
Posts /wp-admin/edit.php8.16 ▲4.8076.78 ▲31.30
Add New Post /wp-admin/post-new.php10.65 ▲4.76115.97 ▲26.36
Media Library /wp-admin/upload.php7.95 ▲4.7261.09 ▲26.94
Staff Templates /wp-admin/edit.php?post_type=cpt_staff_lst8.0459.28
Staff Categories /wp-admin/edit-tags.php?taxonomy=tax_staff_member_cat&post_type=cpt_staff_lst_item7.9957.88
Category Menus /wp-admin/edit.php?post_type=cpt_staff_lst_menu8.0061.08
Groups /wp-admin/edit.php?post_type=cpt_staff_grps8.0055.47
Admin /wp-admin/edit.php?post_type=cpt_staff_lst_item&page=abcfsl-admin-tabs7.9556.43
Staff Members /wp-admin/edit.php?post_type=cpt_staff_lst_item8.0458.12
Add New /wp-admin/post-new.php?post_type=cpt_staff_lst_item8.0568.94
AZ Menus /wp-admin/edit.php?post_type=cpt_staff_az_menu8.0056.52

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 426 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Staff List
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,881 ▲12014.35 ▼0.271.58 ▲0.1238.26 ▼4.04
Dashboard /wp-admin2,273 ▲935.76 ▲0.0996.75 ▲9.9743.06 ▲0.19
Posts /wp-admin/edit.php2,182 ▲822.28 ▲0.2940.91 ▲6.0935.97 ▼1.66
Add New Post /wp-admin/post-new.php1,591 ▲6323.25 ▲0.23643.50 ▼12.1437.01 ▼22.94
Media Library /wp-admin/upload.php1,478 ▲814.33 ▲0.0396.71 ▲0.9642.62 ▼0.76
Staff Templates /wp-admin/edit.php?post_type=cpt_staff_lst1,3273.6346.3926.45
Staff Categories /wp-admin/edit-tags.php?taxonomy=tax_staff_member_cat&post_type=cpt_staff_lst_item1,5203.3342.0631.28
Category Menus /wp-admin/edit.php?post_type=cpt_staff_lst_menu1,1402.2432.7228.00
Groups /wp-admin/edit.php?post_type=cpt_staff_grps1,1402.2332.7030.83
Admin /wp-admin/edit.php?post_type=cpt_staff_lst_item&page=abcfsl-admin-tabs1,0553.2139.2827.47
Staff Members /wp-admin/edit.php?post_type=cpt_staff_lst_item1,4303.5345.8530.55
Add New /wp-admin/post-new.php?post_type=cpt_staff_lst_item2,0833.9067.0183.66
AZ Menus /wp-admin/edit.php?post_type=cpt_staff_az_menu1,1402.3532.9431.85

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded

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)
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 6× 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/staff-list/admin/ajax-handlers.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/staff-list/admin/class-menu.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/staff-list/library/abcfl-attr.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/staff-list/adminf/class-menu.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function abcfl_html_tag() in wp-content/plugins/staff-list/admin/columns.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/staff-list/admin/autil.php:3

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 Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: employee directory, faculty directory, staff directory, church directory, team

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

The primary PHP file in "Staff List" version 1.7.3 is used by WordPress to initiate all plugin functionality
73 characters long description:
Easily create list of staff members. Add single pages, filters and menus.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin26,573 lines of code in 151 files:
LanguageFilesBlank linesComment linesLines of code
PHP1335,3083,91221,083
JavaScript136809502,805
CSS42441181,840
PO File1373388845

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity27.64
▷ Minimum class complexity1.00
▷ Maximum class complexity68.00
Average method complexity2.97
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes19.09%
Methods149
▷ Static methods10.67%
▷ Public methods9765.10%
▷ Protected methods42.68%
▷ Private methods4832.21%
Functions1,101
▷ Named functions1,101100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants480.00%
▷ Class constants120.00%
▷ 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
253 PNG files occupy 0.26MB with 0.09MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/32-70/home.png0.66KB0.52KB▼ 21.48%
images/birthdays-layout-a-title.png0.33KB0.17KB▼ 49.26%
images/48-50/email.png1.05KB0.67KB▼ 36.09%
images/32-70/youtube.png0.83KB0.58KB▼ 30.28%
images/32-70/facebook.png0.69KB0.50KB▼ 28.49%