10% a-simple-backend

Code Review | A Simple Backend

WordPress plugin A Simple Backend scored 10% from 54 tests.

About plugin

  • Plugin page: a-simple-backend
  • Plugin version: 1.0.5.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3.0-5.5.3
  • WordPress version: 5.9.2
  • First release: Feb 7, 2016
  • Latest release: Nov 24, 2020
  • Number of updates: 77
  • Update frequency: every 23.3 days
  • Top authors: evanspress (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active / 3,797 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
You still need to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/a-simple-backend/helpers/Plugin.php+625
    unserialize(): Error at offset 0 of 1 bytes

Server metrics [RAM: ▼1.88MB] [CPU: ▼357.44ms] Passed 4 tests

Analyzing server-side resources used by A Simple Backend
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.49 ▼1.036.52 ▼44.43
Dashboard /wp-admin2.51 ▼0.906.27 ▼30.84
Posts /wp-admin/edit.php2.51 ▼1.147.09 ▼30.26
Add New Post /wp-admin/post-new.php2.51 ▼4.476.27 ▼1,324.23
Media Library /wp-admin/upload.php2.51 ▼0.805.66 ▼25.39

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 46 new files
Database: no new tables, 14 new options
New WordPress options
asimplebackendimage_default_link_type
asimplebackendrss_title
asimplebackendimage_default_size
asimplebackendeditor_hidden
asimplebackendrss_url
asimplebackendmenu
asimplebackendwelcome_message
asimplebackendadmin_hidden
asimplebackenddebugging
asimplebackendsanitized_links
...

Browser metrics Passed 4 tests

Checking browser requirements for A Simple Backend
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,636 ▼1,11816.76 ▲0.7814.94 ▲8.332.33 ▲0.03
Dashboard /wp-admin1,711 ▼1,1506.35 ▲0.11116.55 ▼13.35137.80 ▼21.80
Posts /wp-admin/edit.php2,557 ▼1373.66 ▲0.4194.24 ▲29.79155.76 ▲16.26
Add New Post /wp-admin/post-new.php1,934 ▲21515.54 ▼6.34325.22 ▼91.19170.43 ▲15.60
Media Library /wp-admin/upload.php1,812 ▲1186.30 ▲0.78120.78 ▼50.58185.20 ▼3.45

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/a-simple-backend/helpers/Plugin.php+625
    unserialize(): Error at offset 0 of 1 bytes
  • This plugin did not uninstall successfully, leaving 14 options in the database
    • asimplebackendimage_default_size
    • asimplebackendadmin_hidden
    • asimplebackendmenu
    • asimplebackendimage_default_align
    • asimplebackendsanitized_links
    • asimplebackendrss_url
    • asimplebackendplugins
    • asimplebackendrss_title
    • asimplebackendwelcome_message
    • asimplebackendemail
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
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 applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 4× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/a-simple-backend/views/admin/welcome.php
    • > /wp-content/plugins/a-simple-backend/views/admin/footer.php
    • > /wp-content/plugins/a-simple-backend/views/admin/feed.php
    • > /wp-content/plugins/a-simple-backend/a-simple-backend.php
  • 34× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/a-simple-backend/views/admin/media.php on line 15
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/a-simple-backend/views/admin/page.php on line 15
    • > PHP Notice
      Undefined variable: welcome_message in wp-content/plugins/a-simple-backend/views/admin/welcome.php on line 3
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/a-simple-backend/views/admin/menu.php on line 15
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/a-simple-backend/views/admin/toplink.php on line 5
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/a-simple-backend/views/admin/password.php:5
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/a-simple-backend/views/admin/toplink.php on line 15
    • > PHP Notice
      Undefined variable: name in wp-content/plugins/a-simple-backend/views/admin/toplink.php on line 15
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/a-simple-backend/views/admin/titlewrap.php:1
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/a-simple-backend/views/admin/link.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Tags: Please add at least on tag
You can look at the official readme.txt

a-simple-backend/a-simple-backend.php Passed 13 tests

The main file in "A Simple Backend" v. 1.0.5.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
88 characters long description:
A Simple Backend allows designers to create a minimalist WordPress CMS admin experience!

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected5,306 lines of code in 30 files:
LanguageFilesBlank linesComment linesLines of code
PHP204582703,281
JavaScript83591751,764
CSS2582261

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity108.80
▷ Minimum class complexity1.00
▷ Maximum class complexity354.00
Average method complexity5.53
▷ Minimum method complexity1.00
▷ Maximum method complexity65.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods119
▷ Static methods54.20%
▷ Public methods11899.16%
▷ Protected methods00.00%
▷ Private methods10.84%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
13 PNG files occupy 0.04MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/close_icon.png3.00KB0.45KB▼ 85.03%
images/settings.png3.10KB0.71KB▼ 77.13%
images/duplicate.png0.26KB0.19KB▼ 26.94%
images/nav_icon.png3.25KB0.81KB▼ 75.21%
images/asimlebackend.png3.39KB1.09KB▼ 67.76%