68% 1beyt

Code Review | 1Beyt

WordPress plugin 1Beyt scored68%from 54 tests.

About plugin

  • Plugin page: 1beyt
  • Plugin version: 1.5.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.2.2
  • WordPress version: 6.3.1
  • First release: Mar 15, 2016
  • Latest release: Jun 20, 2019
  • Number of updates: 14
  • Update frequency: every 85.1 days
  • Top authors: ham3da (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /2,434 total downloads


Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.49ms] Passed 4 tests

Server-side resources used by 1Beyt
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0340.39 ▼4.63
Dashboard /wp-admin3.34 ▲0.0348.46 ▼4.30
Posts /wp-admin/edit.php3.39 ▲0.0355.97 ▲6.14
Add New Post /wp-admin/post-new.php5.92 ▲0.0395.27 ▼4.73
Media Library /wp-admin/upload.php3.27 ▲0.0336.45 ▼4.30
یک بیت شعر /wp-admin/admin.php?page=ob_page3.2331.04
ربات یک بیت شعر /wp-admin/admin.php?page=ob_robot3.2332.37

Server storage [IO: ▲1.21MB] [DB: ▲0.82MB] 67% from 3 tests

Analyzing filesystem and database footprints of this plugin
Please fix the following
  • Illegal file modification detected: 1 file (0.00KB) outside of "wp-content/plugins/1beyt/" and "wp-content/uploads/"
    • (new file) "wp-content/plugins/1beyt/banner-772\303\227250.png"
Filesystem: 17 new files
Database: 1 new table, 8 new options
New tables
New WordPress options

Browser metrics Passed 4 tests

Checking browser requirements for 1Beyt
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲2914.10 ▼0.421.82 ▼0.2646.55 ▼0.46
Dashboard /wp-admin2,221 ▲475.55 ▼0.1084.54 ▼2.5278.90 ▲35.91
Posts /wp-admin/edit.php2,132 ▲291.99 ▼0.0238.03 ▼5.3739.35 ▲2.49
Add New Post /wp-admin/post-new.php1,563 ▲3722.98 ▼0.69670.63 ▲4.34164.57 ▲110.70
Media Library /wp-admin/upload.php1,429 ▲354.23 ▲0.0398.90 ▼11.8080.11 ▲30.46
یک بیت شعر /wp-admin/admin.php?page=ob_page8562.0026.1458.84
ربات یک بیت شعر /wp-admin/admin.php?page=ob_robot8312.1528.4741.97

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie tables were found after uninstall: 1 table
    • wp_poems
  • The uninstall procedure has failed, leaving 8 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_ob_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/1beyt/inc/robot.php
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Warning
      Use of undefined constant OB4WP_URL - assumed 'OB4WP_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/1beyt/inc/robot.php on line 12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/1beyt/help.php:32
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/1beyt/inc/widget.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/1beyt/inc/ob_shortcode.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side


Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Add an image for screenshot #1 (Screen shot (screenshot-1.png) Distich Widget.)
The official readme.txt is a good inspiration

1beyt/1beyt.php 92% from 13 tests

This is the main PHP file of "1Beyt" version 1.5.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Description: Keep the plugin description shorter than 140 characters (currently 141 characters long)

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
No dangerous file extensions were detected6,192 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity2.75
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions7100.00%
▷ Anonymous functions00.00%
▷ Global constants4100.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
8 PNG files occupy 0.40MB with 0.21MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/logo.png21.92KB3.16KB▼ 85.58%
icon-256x256.png112.30KB42.83KB▼ 61.86%
screenshot-2.png10.90KB5.36KB▼ 50.83%
screenshot-1.png35.95KB14.54KB▼ 59.54%