84% daily-attendance

Code Review | Daily Attendance

WordPress plugin Daily Attendance scored84%from 54 tests.

About plugin

  • Plugin page: daily-attendance
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Sep 12, 2019
  • Latest release: Sep 12, 2019
  • Number of updates: 3
  • Update frequency: every 1.0 days
  • Top authors: jaedm97 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

3,000+ active /2,540 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▼0.57MB] [CPU: ▼18.55ms] Passed 4 tests

An overview of server-side resources used by Daily Attendance
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1037.79 ▼9.13
Dashboard /wp-admin3.42 ▲0.1148.61 ▼4.77
Posts /wp-admin/edit.php3.51 ▲0.1649.89 ▼1.90
Add New Post /wp-admin/post-new.php3.25 ▼2.6440.04 ▼56.44
Media Library /wp-admin/upload.php3.36 ▲0.1335.05 ▼3.87

Server storage [IO: ▲5.62MB] [DB: ▲0.07MB] Passed 3 tests

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

Browser metrics Passed 4 tests

Checking browser requirements for Daily Attendance
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,838 ▲7714.73 ▲0.351.96 ▲0.3141.61 ▼2.01
Dashboard /wp-admin2,213 ▲335.62 ▼0.0794.21 ▲3.1637.74 ▼5.76
Posts /wp-admin/edit.php2,118 ▲182.03 ▼0.0138.42 ▲0.4436.55 ▲0.22
Add New Post /wp-admin/post-new.php1,543 ▼223.28 ▲0.09614.72 ▼4.9353.65 ▼0.87
Media Library /wp-admin/upload.php1,418 ▲244.30 ▲0.1196.77 ▲0.6040.77 ▼0.37

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

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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 take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/daily-attendance/includes/class-hooks.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
No plugin tags provided

daily-attendance/daily-attendance.php 92% from 13 tests

The primary PHP file in "Daily Attendance" version 1.0.0 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Domain Path: The domain path points to an invalid folder, "/languages/" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin4,124 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
SVG1002,105
PHP75074771,484
CSS412117529
JavaScript21866

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity76.00
▷ Minimum class complexity1.00
▷ Maximum class complexity279.00
Average method complexity4.99
▷ Minimum method complexity1.00
▷ Maximum method complexity25.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods76
▷ Static methods00.00%
▷ Public methods6382.89%
▷ Protected methods00.00%
▷ Private methods1317.11%
Functions8
▷ Named functions787.50%
▷ Anonymous functions112.50%
Constants3
▷ Global constants3100.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.03MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/pb.png33.35KB15.99KB▼ 52.06%