10% personio

Code Review | Personio

WordPress plugin Personio scored10%from 54 tests.

About plugin

  • Plugin page: personio
  • Plugin version: 0.0.3
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.3
  • WordPress version: 6.3.1
  • First release: Jun 27, 2019
  • Latest release: Mar 4, 2020
  • Number of updates: 7
  • Update frequency: every 37.6 days
  • Top authors: tomcat2111 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /808 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Please fix the following installer errors
  • The plugin cannot be installed
    • > Warning in wp-content/plugins/personio/wp-personio.php+29
    Invalid argument supplied for foreach()

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

Analyzing server-side resources used by Personio
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0036.24 ▼10.99
Dashboard /wp-admin3.31 ▼0.0348.66 ▼23.86
Posts /wp-admin/edit.php3.36 ▲0.0145.33 ▼13.15
Add New Post /wp-admin/post-new.php5.89 ▲0.0187.58 ▼16.46
Media Library /wp-admin/upload.php3.24 ▲0.0142.39 ▲7.84
Personio /wp-admin/options-general.php?page=wp-personio3.28380.26

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Personio: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲5714.40 ▲0.092.03 ▲0.1844.24 ▲0.72
Dashboard /wp-admin2,199 ▲285.62 ▼0.0690.04 ▼37.5839.62 ▼12.39
Posts /wp-admin/edit.php2,104 ▲12.00 ▼0.0135.82 ▼13.6832.27 ▼11.78
Add New Post /wp-admin/post-new.php1,548 ▲2222.99 ▲5.43675.55 ▼13.9653.90 ▲4.25
Media Library /wp-admin/upload.php1,401 ▲44.21 ▼0.0699.93 ▼4.5147.55 ▲0.81
Personio /wp-admin/options-general.php?page=wp-personio1,5456.47135.3757.56

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/personio/wp-personio.php:21
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/personio/includes/options-page.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/personio/includes/empty-employees.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/personio/wp-personio-admin.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/personio/wp-personio-shortcodes.php:6

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: employees, hr, personio

personio/wp-personio.php 92% from 13 tests

The main file in "Personio" v. 0.0.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("personio.php" instead of "wp-personio.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin209 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP64630201
HTML1008

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity2.67
▷ Minimum method complexity2.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods133.33%
▷ Public methods266.67%
▷ Protected methods00.00%
▷ Private methods133.33%
Functions7
▷ Named functions685.71%
▷ Anonymous functions114.29%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.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
PNG images were not found in this plugin