74% launchpage-app-importer

Code Review | LaunchPage.app Importer

WordPress plugin LaunchPage.app Importer scored74%from 54 tests.

About plugin

  • Plugin page: launchpage-app-im...
  • Plugin version: 1.1
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-4.9.8
  • WordPress version: 6.3.1
  • First release: Dec 6, 2018
  • Latest release: Dec 11, 2018
  • Number of updates: 3
  • Update frequency: every 2.3 days
  • Top authors: bc2018 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /512 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.30MB] [CPU: ▼1.90ms] Passed 4 tests

A check of server-side resources used by LaunchPage.app Importer
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3338.51 ▼2.10
Dashboard /wp-admin3.64 ▲0.3446.06 ▼7.03
Posts /wp-admin/edit.php3.69 ▲0.3453.04 ▲8.20
Add New Post /wp-admin/post-new.php6.16 ▲0.2785.67 ▲5.97
Media Library /wp-admin/upload.php3.50 ▲0.2733.44 ▼4.45

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 336 new files
Database: 1 new table, 6 new options
New tables
launch_page_importer_content
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

LaunchPage.app Importer: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲7213.34 ▼0.971.75 ▲0.0241.45 ▼1.67
Dashboard /wp-admin2,221 ▲305.84 ▲1.0194.71 ▼5.9138.73 ▼5.17
Posts /wp-admin/edit.php2,107 ▲212.03 ▲0.0339.91 ▲3.2534.48 ▲0.61
Add New Post /wp-admin/post-new.php1,528 ▲1417.50 ▼0.31630.80 ▼57.2657.65 ▲6.84
Media Library /wp-admin/upload.php1,409 ▲244.20 ▼0.0098.02 ▼3.9343.51 ▼1.08

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • This plugin does not fully uninstall, leaving 1 table in the database
    • launch_page_importer_content
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 212× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Handler\\AbstractProcessingHandler' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/src/Monolog/Handler/AmqpHandler.php:20
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/launchpage-app-importer/vendor/guzzlehttp/psr7/src/MultipartStream.php:10
    • > PHP Fatal error
      Uncaught Error: Interface 'Monolog\\Processor\\ProcessorInterface' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/src/Monolog/Processor/UidProcessor.php:21
    • > PHP Fatal error
      Uncaught Error: Interface 'Monolog\\Processor\\ProcessorInterface' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/src/Monolog/Processor/MemoryProcessor.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\TestCase' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/tests/Monolog/Handler/AbstractProcessingHandlerTest.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\TestCase' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/tests/Monolog/Handler/InsightOpsHandlerTest.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\TestCase' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/tests/Monolog/Handler/DynamoDbHandlerTest.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/tests/Monolog/Formatter/ScalarFormatterTest.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'Monolog\\Processor\\ProcessorInterface' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/src/Monolog/Processor/TagProcessor.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Formatter\ormalizerFormatter' not found in wp-content/plugins/launchpage-app-importer/vendor/monolog/monolog/src/Monolog/Formatter/WildfireFormatter.php:23

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: sale page, landing pages, landing page

launchpage-app-importer/index.php 92% from 13 tests

Analyzing the main PHP file in "LaunchPage.app Importer" version 1.1
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("launchpage-app-importer.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected26,873 lines of code in 316 files:
LanguageFilesBlank linesComment linesLines of code
PHP2844,94211,06322,129
Markdown181,23103,992
JSON800676
XML27034
YAML14014
Sass12012
make1409
CSS1117

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity7.86
▷ Minimum class complexity1.00
▷ Maximum class complexity81.00
Average method complexity2.07
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces19
Interfaces21
Traits4
Classes254
▷ Abstract classes72.76%
▷ Concrete classes24797.24%
▷ Final classes83.24%
Methods1,784
▷ Static methods1015.66%
▷ Public methods1,41979.54%
▷ Protected methods17910.03%
▷ Private methods18610.43%
Functions235
▷ Named functions7531.91%
▷ Anonymous functions16068.09%
Constants108
▷ Global constants43.70%
▷ Class constants10496.30%
▷ Public constants104100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.04MB with 0.03MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
bundle/css/images/next_button.png16.98KB1.68KB▼ 90.09%
bundle/css/images/prev_button.png17.01KB1.70KB▼ 90.00%
bundle/css/images/owl.video.play.png4.86KB2.74KB▼ 43.61%