79% beans-simple-edits

Code Review | Beans Simple Edits

WordPress plugin Beans Simple Edits scored 79% from 54 tests.

About plugin

  • Plugin page: beans-simple-edits
  • Plugin version: 1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.9.6
  • WordPress version: 6.3.1
  • First release: Jul 5, 2018
  • Latest release: Jul 5, 2018
  • Number of updates: 6
  • Update frequency: every 1.5 days
  • Top authors: Deftly (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 632 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

Server-side resources used by Beans Simple Edits
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0036.97 ▼1.48
Dashboard /wp-admin3.31 ▲0.0043.77 ▼6.18
Posts /wp-admin/edit.php3.36 ▲0.0047.85 ▲1.50
Add New Post /wp-admin/post-new.php5.89 ▲0.00101.57 ▲4.23
Media Library /wp-admin/upload.php3.23 ▲0.0030.98 ▼3.87

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Beans Simple Edits
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.27 ▼1.114.82 ▲3.2141.42 ▲3.93
Dashboard /wp-admin2,206 ▲184.88 ▼1.02113.43 ▲10.8541.60 ▲1.58
Posts /wp-admin/edit.php2,089 ▼02.06 ▲0.0940.32 ▲2.1035.00 ▼3.16
Add New Post /wp-admin/post-new.php1,514 ▼617.62 ▼5.48673.41 ▲34.2649.84 ▼3.33
Media Library /wp-admin/upload.php1,388 ▼34.24 ▼0.01102.34 ▲1.2044.66 ▲1.55

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
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

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 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/beans-simple-edits/beans-simple-edits.php
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/beans-simple-edits/src/views/admin.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function LearningCurve\\BeansSimpleEdits\\add_action() in wp-content/plugins/beans-simple-edits/src/class-beans-simple-edits.php:109

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: post-meta, beans html api, post-info, beans framework, footer

beans-simple-edits/beans-simple-edits.php Passed 13 tests

"Beans Simple Edits" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
139 characters long description:
Beans Simple Edits lets you edit three commonly modified areas in any Beans Child theme: the post-info, the post-meta, and the footer area.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected702 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP5172236408
Markdown2670294

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity6.00
▷ Minimum class complexity2.00
▷ Maximum class complexity13.00
Average method complexity1.75
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods20
▷ Static methods00.00%
▷ Public methods20100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected