78% mass-pagesposts-creator

Code Review | Mass Pages/Posts Creator

WordPress plugin Mass Pages/Posts Creator scored78%from 54 tests.

About plugin

  • Plugin page: mass-pagesposts-c...
  • Plugin version: 2.1.8
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Feb 6, 2015
  • Latest release: Nov 20, 2023
  • Number of updates: 169
  • Update frequency: every 19.0 days
  • Top authors: dots (100%)

Code review

54 tests

User reviews

17 reviews

Install metrics

1,000+ active /59,276 total downloads

Benchmarks

Plugin footprint 64% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲5.09MB] [CPU: ▲20.66ms] 50% from 4 tests

Server-side resources used by Mass Pages/Posts Creator
Please fix the following
  • CPU: The total CPU usage must kept under 500.00ms (currently 1,883.78ms on /wp-admin/admin.php?page=mass-pages-posts-creator)
  • Extra RAM: Extra memory usage should kept under 5MB (currently 5.09MB on /wp-admin/admin.php?page=mass-pages-posts-creator)
PageMemory (MB)CPU Time (ms)
Home /9.00 ▲5.5360.45 ▲22.13
Dashboard /wp-admin9.02 ▲5.6770.26 ▲6.60
Posts /wp-admin/edit.php9.02 ▲5.6684.83 ▲41.04
Add New Post /wp-admin/post-new.php9.38 ▲3.49107.55 ▲19.52
Media Library /wp-admin/upload.php9.02 ▲5.7969.13 ▲34.38
Getting Started /wp-admin/admin.php?page=mppc-get-started9.0268.12
Quick info /wp-admin/admin.php?page=mppc-information9.0261.48
Freemius Debug [v.2.6.0] /wp-admin/admin.php?page=freemius9.0260.19
Mass Pages/Posts Creator for WordPress /wp-admin/admin.php?page=mass-pages-posts-creator9.021,883.78

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 265 new files
Database: no new tables, 9 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-posts
fs_accounts
fs_active_plugins
fs_debug_mode
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Mass Pages/Posts Creator
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,869 ▲12214.35 ▲0.101.85 ▲0.1628.17 ▼13.05
Dashboard /wp-admin2,237 ▲565.56 ▼0.1893.70 ▼7.8179.58 ▲39.05
Posts /wp-admin/edit.php2,158 ▲581.97 ▲0.0340.04 ▲0.7937.22 ▲3.91
Add New Post /wp-admin/post-new.php1,565 ▲2922.83 ▼0.27734.87 ▲63.4761.89 ▼4.74
Media Library /wp-admin/upload.php1,451 ▲544.12 ▼0.1199.94 ▼10.0576.42 ▲26.61
Getting Started /wp-admin/admin.php?page=mppc-get-started1,3362.2233.3577.43
Quick info /wp-admin/admin.php?page=mppc-information1,3862.1930.8249.23
Freemius Debug [v.2.6.0] /wp-admin/admin.php?page=freemius1,1121.6723.1226.83
Mass Pages/Posts Creator for WordPress /wp-admin/admin.php?page=mass-pages-posts-creator1,0592.2131.7659.15

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • The plugin did not uninstall gracefully
    • > Notice in wp-content/plugins/mass-pagesposts-creator/freemius/includes/class-freemius.php+8546
    Undefined property: stdClass::$plugins
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • fs_debug_mode
    • fs_active_plugins
    • can_compress_scripts
    • widget_recent-posts
    • fs_accounts
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests Passed 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 everything seems fine, this is not an exhaustive test

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention: You can look at the official readme.txt

mass-pagesposts-creator/mass-pages-posts-creator.php 85% from 13 tests

"Mass Pages/Posts Creator" version 2.1.8's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("mass-pagesposts-creator.php" instead of "mass-pages-posts-creator.php")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin37,942 lines of code in 159 files:
LanguageFilesBlank linesComment linesLines of code
PHP1268,18117,45034,813
CSS2246831,471
PO File45286841,269
JavaScript55065387
SVG2002

PHP code 50% from 2 tests

An overview of cyclomatic complexity and code structure
Please tend to the following items
  • Class cyclomatic complexity has to be reduced to less than 1000 (currently 3,096)
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity86.09
▷ Minimum class complexity1.00
▷ Maximum class complexity3,096.00
Average method complexity4.60
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces0
Interfaces1
Traits0
Classes52
▷ Abstract classes23.85%
▷ Concrete classes5096.15%
▷ Final classes00.00%
Methods1,282
▷ Static methods19915.52%
▷ Public methods88268.80%
▷ Protected methods171.33%
▷ Private methods38329.88%
Functions119
▷ Named functions119100.00%
▷ Anonymous functions00.00%
Constants149
▷ Global constants10268.46%
▷ Class constants4731.54%
▷ Public constants47100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
57 compressed PNG files occupy 1.24MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/images/ui-icons_888888_256x240.png4.27KB4.11KB▼ 3.78%
admin/css/images/ui-icons_555555_256x240.png6.82KB4.17KB▼ 38.82%
css/images/ui-icons_888888_256x240.png.png4.27KB4.11KB▼ 3.78%
css/images/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%
css/images/ui-bg_glass_75_dadada_1x400.png0.11KB0.16KB0.00%