88% awesome-employee-list

Code Review | Awesome Employee List

WordPress plugin Awesome Employee List scored 88% from 54 tests.

About plugin

  • Plugin page: awesome-employee-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7
  • WordPress version: 5.8.1
  • First release: Feb 17, 2017
  • Latest release: Oct 26, 2018
  • Number of updates: 9
  • Update frequency: every 68.4 days
  • Top authors: raihancse (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 522 total downloads

Benchmarks

Plugin footprint Passed 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.28MB] [CPU: ▼151.83ms] Passed 4 tests

Server-side resources used by Awesome Employee List
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.91 ▲0.1932.19 ▲11.25
Dashboard /wp-admin3.13 ▲0.0747.37 ▲0.29
Posts /wp-admin/edit.php3.18 ▲0.0744.61 ▲3.22
Add New Post /wp-admin/post-new.php4.11 ▼1.3249.46 ▼602.21
Media Library /wp-admin/upload.php3.07 ▲0.0631.44 ▼8.62
All Employee /wp-admin/edit.php?post_type=employee_list3.1131.26
Add New /wp-admin/post-new.php?post_type=employee_list3.0034.87
Employee Type /wp-admin/edit-tags.php?taxonomy=employee_type&post_type=employee_list3.0732.90

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for Awesome Employee List
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,866 ▲27016.40 ▲0.6519.44 ▲7.7875.53 ▲29.47
Dashboard /wp-admin3,014 ▲806.16 ▼0.01138.15 ▼29.96111.49 ▼1.53
Posts /wp-admin/edit.php2,786 ▲472.75 ▲0.0469.32 ▲0.9490.44 ▲3.43
Add New Post /wp-admin/post-new.php1,532 ▼15118.58 ▲0.01371.82 ▼55.35104.08 ▼25.41
Media Library /wp-admin/upload.php1,860 ▲535.08 ▲0.07140.41 ▼14.95117.73 ▼8.26
All Employee /wp-admin/edit.php?post_type=employee_list1,4652.7763.5074.27
Add New /wp-admin/post-new.php?post_type=employee_list3,1969.17216.77143.36
Employee Type /wp-admin/edit-tags.php?taxonomy=employee_type&post_type=employee_list1,7902.5758.5881.49

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/post-new.php?post_type=employee_list
    • > Notice in wp-content/plugins/awesome-employee-list/init.php+168
    Undefined index: father
    • > GET request to /wp-admin/post-new.php?post_type=employee_list
    • > Notice in wp-content/plugins/awesome-employee-list/init.php+169
    Undefined index: mother
    • > GET request to /wp-admin/post-new.php?post_type=employee_list
    • > Notice in wp-content/plugins/awesome-employee-list/init.php+170
    Undefined index: gender
    • > GET request to /wp-admin/post-new.php?post_type=employee_list
    • > Notice in wp-content/plugins/awesome-employee-list/init.php+171
    Undefined index: designation
    • > GET request to /wp-admin/post-new.php?post_type=employee_list
    • > Notice in wp-content/plugins/awesome-employee-list/init.php+173
    Undefined index: skills

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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/awesome-employee-list/init.php:12

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === awesome-employee-list === )
The official readme.txt might help

awesome-employee-list/init.php 92% from 13 tests

The principal PHP file in "Awesome Employee List" v. 1.0 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("awesome-employee-list.php" instead of "init.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected327 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP1987199
CSS3185120
JavaScript2358

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity1.56
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods9100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
There are no PNG files in this plugin