83% duplicate-pp

Code Review | Duplicate Post, Page and Any Custom Post

WordPress plugin Duplicate Post, Page and Any Custom Post scored83%from 54 tests.

About plugin

  • Plugin page: duplicate-pp
  • Plugin version: 3.5.1
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Sep 2, 2019
  • Latest release: Nov 8, 2023
  • Number of updates: 38
  • Update frequency: every 40.2 days
  • Top authors: binsaifullah (100%)

Code review

54 tests

User reviews

17 reviews

Install metrics

10,000+ active /126,926 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼3.94ms] Passed 4 tests

An overview of server-side resources used by Duplicate Post, Page and Any Custom Post
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0537.29 ▼6.58
Dashboard /wp-admin3.40 ▲0.0950.09 ▲1.55
Posts /wp-admin/edit.php3.51 ▲0.1546.41 ▼5.25
Add New Post /wp-admin/post-new.php6.00 ▲0.1193.36 ▼5.49
Media Library /wp-admin/upload.php3.32 ▲0.0941.24 ▲7.27
Duplicate PP /wp-admin/tools.php?page=duplicate-pp3.2930.84

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for Duplicate Post, Page and Any Custom Post
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,837 ▲7514.59 ▲0.191.75 ▼0.0745.28 ▲1.93
Dashboard /wp-admin2,242 ▲625.51 ▼0.1387.99 ▼13.6542.61 ▼1.13
Posts /wp-admin/edit.php2,152 ▲552.15 ▲0.1237.71 ▼1.5531.45 ▼4.50
Add New Post /wp-admin/post-new.php1,570 ▲4422.92 ▼0.45606.58 ▼89.6654.74 ▼5.88
Media Library /wp-admin/upload.php1,444 ▲474.20 ▼0.0199.14 ▼5.8043.20 ▼5.00
Duplicate PP /wp-admin/tools.php?page=duplicate-pp9621.9924.3250.23

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts

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 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/duplicate-pp/admin/admin.php:11

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Requires at least: Version format is invalid
You can take inspiration from this readme.txt

duplicate-pp/duplicate-pp.php 85% from 13 tests

"Duplicate Post, Page and Any Custom Post" version 3.5.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist
  • Description: Keep the plugin description shorter than 140 characters (currently 155 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
Success! There were no dangerous files found in this plugin708 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP6103190516
CSS2270161
JavaScript11031

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 issues
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity18.00
▷ Minimum class complexity4.00
▷ Maximum class complexity32.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods00.00%
▷ Public methods17100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.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
PNG images were not found in this plugin