84% nightingale-companion

Code Review | Nightingale Companion

WordPress plugin Nightingale Companion scored84%from 54 tests.

About plugin

  • Plugin page: nightingale-compa...
  • Plugin version: 1.3.6
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.0
  • WordPress version: 6.3.1
  • First release: Jun 22, 2020
  • Latest release: May 12, 2023
  • Number of updates: 13
  • Update frequency: every 81.9 days
  • Top authors: nicksummerfield (92.31%)nhsleadership (15.38%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /4,134 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
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼1.37ms] Passed 4 tests

An overview of server-side resources used by Nightingale Companion
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0036.88 ▼8.15
Dashboard /wp-admin3.31 ▲0.0049.82 ▼2.13
Posts /wp-admin/edit.php3.36 ▲0.0059.54 ▲14.20
Add New Post /wp-admin/post-new.php5.89 ▲0.00106.35 ▲3.87
Media Library /wp-admin/upload.php3.23 ▲0.0036.74 ▲0.92

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 25 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
db_upgraded
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

Nightingale Companion: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.32 ▲0.041.89 ▼0.1245.12 ▲2.20
Dashboard /wp-admin2,195 ▲155.51 ▼0.1486.26 ▼0.1438.24 ▼0.54
Posts /wp-admin/edit.php2,100 ▼02.00 ▼0.0841.61 ▲3.0540.09 ▲1.71
Add New Post /wp-admin/post-new.php1,528 ▼723.08 ▲4.91704.40 ▲96.4255.08 ▼4.63
Media Library /wp-admin/upload.php1,400 ▲34.24 ▲0.01102.09 ▲4.6243.77 ▲2.80

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 does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

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 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 15× 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_action() in wp-content/plugins/nightingale-companion/functionality/simple-meta.php:26
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/performance/disable-emojis.php:26
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/display/author-bio.php:57
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/display/audio-playback.php:96
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/display/login.php:32
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/display/social-sharing.php:51
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_theme_mod() in wp-content/plugins/nightingale-companion/display/social-links.php:22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/display/posts-by-author.php:74
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nightingale-companion/display/customizer.php:148
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/nightingale-companion/display/partials/emergency-alert.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention: You can take inspiration from this readme.txt

nightingale-companion/nightingale-companion.php Passed 13 tests

The entry point to "Nightingale Companion" version 1.3.6 is a PHP file that has certain tags in its header comment area
50 characters long description:
A plugin to add in more functionality to the theme

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
Success! There were no dangerous files found in this plugin1,993 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
PHP182294561,669
JavaScript35636199
CSS18976
Markdown238049

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.51
Average class complexity145.00
▷ Minimum class complexity145.00
▷ Maximum class complexity145.00
Average method complexity8.20
▷ Minimum method complexity1.00
▷ Maximum method complexity50.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods20
▷ Static methods00.00%
▷ Public methods1050.00%
▷ Protected methods1050.00%
▷ Private methods00.00%
Functions40
▷ Named functions2460.00%
▷ Anonymous functions1640.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
No PNG images were found in this plugin