83% dbc-backup-2

Code Review | DBC Backup 2

WordPress plugin DBC Backup 2 scored 83% from 54 tests.

About plugin

  • Plugin page: dbc-backup-2
  • Plugin version: 2.3.25
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-3.8
  • WordPress version: 6.3.1
  • First release: Jul 10, 2012
  • Latest release: Jan 5, 2014
  • Number of updates: 49
  • Update frequency: every 13.2 days
  • Top authors: damiensaunders (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active / 14,733 total downloads


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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼6.66ms] Passed 4 tests

Server-side resources used by DBC Backup 2
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0734.26 ▼6.08
Dashboard /wp-admin3.38 ▲0.0744.15 ▼3.25
Posts /wp-admin/edit.php3.49 ▲0.1347.51 ▲0.20
Add New Post /wp-admin/post-new.php5.96 ▲0.0792.45 ▼11.96
Media Library /wp-admin/upload.php3.30 ▲0.0732.71 ▼5.35
DBC Backup /wp-admin/tools.php?page=dbc_backup_admin3.3537.80

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, 7 new options
New WordPress options

Browser metrics Passed 4 tests

A check of browser resources used by DBC Backup 2
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲9413.62 ▼0.761.77 ▼0.0137.28 ▼2.32
Dashboard /wp-admin2,210 ▲224.87 ▼0.0196.01 ▼10.1237.86 ▼0.69
Posts /wp-admin/edit.php2,093 ▲72.03 ▲0.0634.17 ▼0.3834.99 ▲0.65
Add New Post /wp-admin/post-new.php1,540 ▲2618.47 ▲0.76589.30 ▼107.3756.89 ▲1.07
Media Library /wp-admin/upload.php1,392 ▲44.19 ▼0.0392.74 ▼17.0642.42 ▼4.99
DBC Backup /wp-admin/tools.php?page=dbc_backup_admin2,5753.2765.1937.05

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 75% 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)
Even though no errors were found, 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 items
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/dbc-backup-2/inc/backup_run.php:57
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/dbc-backup-2/inc/admin_functions.php:23

User-side errors Passed 1 test

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


Plugin configuration 90% from 29 tests

readme.txt 88% 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:
  • Donate link: Invalid url: ""
  • Screenshots: Please add an image for screenshot #1 (Configuration settings and guidance notes)
Please take inspiration from this readme.txt

dbc-backup-2/dbcbackup.php 92% from 13 tests

The primary PHP file in "DBC Backup 2" version 2.3.25 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("dbc-backup-2.php" instead of "dbcbackup.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected749 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions22100.00%
▷ Anonymous functions00.00%
▷ Global constants9100.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
There are no PNG files in this plugin