78% altruja

Code Review | Altruja

WordPress plugin Altruja scored78%from 54 tests.

About plugin

  • Plugin page: altruja
  • Plugin version: 1.0.7
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-6.2
  • WordPress version: 6.3.1
  • First release: Jul 18, 2014
  • Latest release: Apr 28, 2023
  • Number of updates: 26
  • Update frequency: every 123.3 days
  • Top authors: altruja (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /3,303 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
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼5.29ms] Passed 4 tests

This is a short check of server-side resources used by Altruja
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.40 ▼0.0628.49 ▼12.40
Dashboard /wp-admin3.33 ▲0.0349.94 ▼1.90
Posts /wp-admin/edit.php3.38 ▲0.0351.17 ▲4.29
Add New Post /wp-admin/post-new.php5.91 ▲0.0385.91 ▼11.16
Media Library /wp-admin/upload.php3.26 ▲0.0340.81 ▲7.52
Altruja /wp-admin/options-general.php?page=altruja3.2033.76

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for Altruja
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6013.26 ▼1.112.02 ▲0.0341.80 ▼5.59
Dashboard /wp-admin2,207 ▲195.78 ▼0.10101.31 ▼14.0940.33 ▼4.90
Posts /wp-admin/edit.php2,093 ▲41.99 ▼0.0633.75 ▼2.4138.98 ▼1.16
Add New Post /wp-admin/post-new.php1,541 ▲2423.06 ▲5.34660.32 ▼12.0155.29 ▼2.37
Media Library /wp-admin/upload.php1,392 ▲44.21 ▲0.0298.81 ▼8.8544.20 ▼4.50
Altruja /wp-admin/options-general.php?page=altruja7812.0524.4426.15

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=altruja
    • > Notice in wp-content/plugins/altruja/admin.php+78
    Trying to access array offset on value of type bool

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 items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/altruja/main.php:7

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 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
  • Contributors: Contributors not specified
You can look at the official readme.txt

altruja/altruja.php Passed 13 tests

The main PHP script in "Altruja" version 1.0.7 is automatically included on every request by WordPress
108 characters long description:
Einfach. Online. Spenden sammeln. Altruja is a fast, simple and trustworthy way to collect donations online.

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
Success! There were no dangerous files found in this plugin104 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP34727101
PO File1203

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity2.00
▷ Minimum class complexity1.00
▷ Maximum class complexity4.00
Average method complexity1.23
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods13
▷ Static methods215.38%
▷ Public methods13100.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

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin