77% die-eule-netzwerk

Code Review | Die Eule Vernetzt

WordPress plugin Die Eule Vernetzt scored77%from 54 tests.

About plugin

  • Plugin page: die-eule-netzwerk
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.8.1
  • WordPress version: 6.3.1
  • First release: Jul 21, 2018
  • Latest release: Nov 2, 2021
  • Number of updates: 8
  • Update frequency: every 150.1 days
  • Top authors: maxmelzer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /725 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.21MB] [CPU: ▼16.16ms] Passed 4 tests

Analyzing server-side resources used by Die Eule Vernetzt
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.14 ▼1.325.66 ▼33.74
Dashboard /wp-admin3.53 ▲0.1849.29 ▼15.92
Posts /wp-admin/edit.php3.58 ▲0.2249.59 ▼0.33
Add New Post /wp-admin/post-new.php6.05 ▲0.1689.17 ▼14.64
Media Library /wp-admin/upload.php3.39 ▲0.1642.71 ▲6.00
Die Eule vernetzt /wp-admin/options-general.php?page=die_eule_vernetzt3.3631.50

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 94 new files
Database: no new tables, 7 new options
New WordPress options
widget_eulenetzwerk
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Die Eule Vernetzt
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,797 ▲1114.69 ▲0.541.76 ▼0.0843.73 ▲1.08
Dashboard /wp-admin2,202 ▲285.62 ▼0.0488.07 ▼7.2944.30 ▲4.01
Posts /wp-admin/edit.php2,101 ▲12.01 ▲0.0335.01 ▼3.8637.97 ▲2.56
Add New Post /wp-admin/post-new.php1,531 ▲523.17 ▲0.06670.35 ▲15.8357.25 ▲3.10
Media Library /wp-admin/upload.php1,404 ▲74.14 ▼0.08114.92 ▼4.7149.44 ▼0.16
Die Eule vernetzt /wp-admin/options-general.php?page=die_eule_vernetzt8032.0025.7227.36

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
Please fix the following items
  • The uninstall procedure has failed, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_eulenetzwerk
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/die-eule-netzwerk/eule-network.php
  • 17× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\Block' not found in wp-content/plugins/die-eule-netzwerk/src/Block/Section.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\Block' not found in wp-content/plugins/die-eule-netzwerk/src/Block/PartnerFeed.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\AbstractPostAction' not found in wp-content/plugins/die-eule-netzwerk/src/Model/Action/RefreshFeed.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\Block' not found in wp-content/plugins/die-eule-netzwerk/src/Block/Setting.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'SimplePie_Cache_DB' not found in wp-content/plugins/die-eule-netzwerk/vendor/simplepie/simplepie/library/SimplePie/Cache/MySQL.php:56
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\Config\\Setting' not found in wp-content/plugins/die-eule-netzwerk/src/Config/Setting/Select.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\Block' not found in wp-content/plugins/die-eule-netzwerk/src/Block/Settings.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'SimplePie' not found in wp-content/plugins/die-eule-netzwerk/vendor/simplepie/simplepie/library/SimplePie/Core.php:53
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/die-eule-netzwerk/src/Widget/PartnerFeed.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'EuleNetwork\\AdminPage' not found in wp-content/plugins/die-eule-netzwerk/src/Config/Settings.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 86% 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 require attention: Please take inspiration from this readme.txt

die-eule-netzwerk/eule-network.php 77% from 13 tests

The entry point to "Die Eule Vernetzt" version 1.0.1 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Domain Path: The domain path folder was not found ("/languages")
  • Main file name: The principal plugin file should be the same as the plugin slug ("die-eule-netzwerk.php" instead of "eule-network.php")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected15,211 lines of code in 85 files:
LanguageFilesBlank linesComment linesLines of code
PHP781,7816,75414,892
JSON300109
Markdown127086
CSS111071
SQL14432
YAML10021

PHP code 50% from 2 tests

A short review of cyclomatic complexity and code structure
The following items need your attention
  • Cyclomatic complexity of methods has to be reduced to less than 100 (currently 808)
Cyclomatic complexity
Average complexity per logical line of code0.68
Average class complexity52.40
▷ Minimum class complexity1.00
▷ Maximum class complexity949.00
Average method complexity6.60
▷ Minimum method complexity1.00
▷ Maximum method complexity808.00
Code structure
Namespaces10
Interfaces1
Traits0
Classes61
▷ Abstract classes23.28%
▷ Concrete classes5996.72%
▷ Final classes00.00%
Methods577
▷ Static methods559.53%
▷ Public methods53091.85%
▷ Protected methods356.07%
▷ Private methods122.08%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.00%
Constants82
▷ Global constants7085.37%
▷ Class constants1214.63%
▷ Public constants12100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
src/img/logo_gray_medium.png8.27KB3.74KB▼ 54.72%
src/img/logo_white_medium.png21.85KB7.20KB▼ 67.06%