84% nifty-backups

Code Review | Backup WordPress with Nifty Backups

WordPress plugin Backup WordPress with Nifty Backups scored84%from 54 tests.

About plugin

  • Plugin page: nifty-backups
  • Plugin version: 1.08
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-4.7
  • WordPress version: 6.3.1
  • First release: Nov 13, 2016
  • Latest release: Nov 25, 2016
  • Number of updates: 11
  • Update frequency: every 10.8 days
  • Top authors: NickDuncan (100%)

Code review

54 tests

User reviews

12 reviews

Install metrics

100+ active /5,032 total downloads

Benchmarks

Plugin footprint 83% 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.10MB] [CPU: ▼17.39ms] Passed 4 tests

This is a short check of server-side resources used by Backup WordPress with Nifty Backups
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.09 ▲0.6342.33 ▲0.81
Dashboard /wp-admin3.92 ▲0.5845.43 ▼17.09
Posts /wp-admin/edit.php3.97 ▲0.6246.33 ▲7.44
Add New Post /wp-admin/post-new.php3.74 ▼2.1538.88 ▼57.05
Media Library /wp-admin/upload.php3.78 ▲0.5637.86 ▲3.76

Server storage [IO: ▲0.57MB] [DB: ▲0.07MB] Passed 3 tests

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 36 new files
Database: no new tables, 8 new options
New WordPress options
nifty_backups_api_secret_token
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
nifty_bu_version
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Backup WordPress with Nifty Backups
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲8314.25 ▼0.121.88 ▼0.1037.06 ▼8.37
Dashboard /wp-admin2,213 ▲365.57 ▼0.0184.17 ▼5.4958.80 ▲11.93
Posts /wp-admin/edit.php2,094 ▼91.99 ▼0.0236.19 ▼3.2234.10 ▼4.34
Add New Post /wp-admin/post-new.php1,554 ▲1923.09 ▲4.75709.03 ▲73.5349.55 ▼18.85
Media Library /wp-admin/upload.php1,415 ▲154.22 ▲0.0496.63 ▲0.8670.62 ▲29.48

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin does not fully uninstall, leaving 8 options in the database
    • nifty_bu_version
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • nifty_backups_api_secret_token
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not 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 take a closer look at the following
  • 18× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/nifty-backups/includes/module_notifications.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/nifty-backups/templates/restore_file.php:21
    • > PHP Warning
      Use of undefined constant nifty_bu_upload_dir - assumed 'nifty_bu_upload_dir' (this will throw an Error in a future version of PHP) in wp-content/plugins/nifty-backups/templates/restore_db.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/nifty-backups/templates/restore.php:13
    • > PHP Notice
      Undefined index: extra_item in wp-content/plugins/nifty-backups/templates/restore_db.php on line 13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/nifty-backups/templates/support.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/nifty-backups/includes/module_offsite_email.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nifty-backups/includes/REST_api.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/nifty-backups/templates/db_settings.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/nifty-backups/templates/welcome.php:4

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Tags: You are using too many tags: 18 tag instead of maximum 10
You can look at the official readme.txt

nifty-backups/nifty-backups.php Passed 13 tests

The primary PHP file in "Backup WordPress with Nifty Backups" version 1.08 is used by WordPress to initiate all plugin functionality
61 characters long description:
The easiest to use and most reliable WordPress Backup Plugin.

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
Everything looks great! No dangerous files found in this plugin4,599 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
PHP161,1314283,054
PO File1208242494
CSS4655482
JavaScript28626482
HTML36087

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity373.00
▷ Minimum class complexity373.00
▷ Maximum class complexity373.00
Average method complexity4.88
▷ Minimum method complexity1.00
▷ Maximum method complexity34.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods91
▷ Static methods44.40%
▷ Public methods7076.92%
▷ Protected methods00.00%
▷ Private methods2123.08%
Functions20
▷ Named functions1995.00%
▷ Anonymous functions15.00%
Constants5
▷ Global constants5100.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
6 PNG files occupy 0.09MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/niftybackups_32px.png4.56KB1.69KB▼ 62.96%
images/nifty_backups_logo.png63.25KB19.42KB▼ 69.29%
images/niftybackups_18px.png0.80KB1.00KB0.00%
images/nifty-backups.png9.79KB3.37KB▼ 65.59%
images/niftybackups_18px_grey.png0.80KB1.01KB0.00%