84% rajce

Code Review | Rajce

WordPress plugin Rajce scored84%from 54 tests.

About plugin

  • Plugin page: rajce
  • Plugin version: 0.4.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: Jan 22, 2015
  • Latest release: May 29, 2022
  • Number of updates: 13
  • Update frequency: every 206.5 days
  • Top authors: vEnCa-X (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,671 total downloads

Benchmarks

Plugin footprint 82% 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 gracefully, with no errors

Server metrics [RAM: ▲0.20MB] [CPU: ▼1.95ms] Passed 4 tests

This is a short check of server-side resources used by Rajce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.69 ▲0.2340.34 ▲1.80
Dashboard /wp-admin3.54 ▲0.2349.85 ▼3.03
Posts /wp-admin/edit.php3.59 ▲0.2349.75 ▼4.10
Add New Post /wp-admin/post-new.php6.05 ▲0.1797.27 ▲1.58
Media Library /wp-admin/upload.php3.40 ▲0.1737.97 ▼2.23

Server storage [IO: ▲0.05MB] [DB: ▲0.00MB] 67% from 3 tests

Input-output and database impact of this plugin
Just a few items left to fix
  • There were 1 file (4.00KB) illegally modified outside of "wp-content/plugins/rajce/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 21 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_rajce_widget
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Rajce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5413.25 ▼1.051.67 ▲0.0537.70 ▼3.49
Dashboard /wp-admin2,224 ▲175.86 ▼0.04107.18 ▼4.2943.34 ▼1.25
Posts /wp-admin/edit.php2,100 ▼32.01 ▼0.0442.90 ▲0.5834.99 ▼1.48
Add New Post /wp-admin/post-new.php1,545 ▼023.37 ▲0.13587.94 ▼5.5458.53 ▲8.35
Media Library /wp-admin/upload.php1,400 ▲64.19 ▼0.08103.05 ▲5.3444.66 ▼1.86

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_rajce_widget
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • 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
Everything seems fine, however this is by no means an exhaustive test

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
Please fix the following
  • 7× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Interface 'WPFW\\Forms\\IControl' not found in wp-content/plugins/rajce/WPFW/Forms/Controls/BaseControl.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'WPFW\\Forms\\Controls\\BaseControl' not found in wp-content/plugins/rajce/WPFW/Forms/Controls/SubmitButton.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'WPFW\\Forms\\Controls\\BaseControl' not found in wp-content/plugins/rajce/WPFW/Forms/Controls/TextInput.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'WPFW\\Caching\\IStorage' not found in wp-content/plugins/rajce/WPFW/Caching/Storages/FileStorage.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'WPFW\\Forms\\Controls\\BaseControl' not found in wp-content/plugins/rajce/WPFW/Forms/Controls/CheckBox.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/rajce/includes/rajce_widget.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/rajce/WPFW/bootstrap.php:4

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 Passed 29 tests

readme.txt Passed 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
2 plugin tags: raje, fotogalerie

rajce/rajce.php Passed 13 tests

"Rajce" version 0.4.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
58 characters long description:
Plugin pro zobrazení galerií z http://www.rajce.idnes.cz

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 detected934 lines of code in 20 files:
LanguageFilesBlank linesComment linesLines of code
PHP20309455934

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity5.56
▷ Minimum class complexity1.00
▷ Maximum class complexity18.00
Average method complexity1.94
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces5
Interfaces2
Traits0
Classes16
▷ Abstract classes00.00%
▷ Concrete classes16100.00%
▷ Final classes00.00%
Methods92
▷ Static methods1111.96%
▷ Public methods7682.61%
▷ Protected methods33.26%
▷ Private methods1314.13%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants00.00%
▷ Class constants4100.00%
▷ Public constants4100.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
No PNG files were detected