66% portfolio-builder-awesome

Code Review | Portfolio Awesome - Responsive WordPress Porfolio Plugin

WordPress plugin Portfolio Awesome - Responsive WordPress Porfolio Plugin scored66%from 54 tests.

About plugin

  • Plugin page: portfolio-builder...
  • Plugin version: 1.1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1
  • WordPress version: 6.3.1
  • First release: Nov 2, 2020
  • Latest release: Dec 16, 2022
  • Number of updates: 27
  • Update frequency: every 28.8 days
  • Top authors: themesawesome (100%)

Code review

54 tests

User reviews

1 review

Install metrics

300+ active /4,106 total downloads

Benchmarks

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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲2.57MB] [CPU: ▲16.80ms] Passed 4 tests

An overview of server-side resources used by Portfolio Awesome - Responsive WordPress Porfolio Plugin
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /6.28 ▲2.8268.87 ▲29.29
Dashboard /wp-admin6.14 ▲2.8486.80 ▲32.74
Posts /wp-admin/edit.php6.17 ▲2.8181.25 ▲27.82
Add New Post /wp-admin/post-new.php7.78 ▲1.9076.69 ▼18.65
Media Library /wp-admin/upload.php5.99 ▲2.7764.19 ▲28.74
Add New Portfolio /wp-admin/post-new.php?post_type=portfolio-awesome7.7875.34
Portfolio Item /wp-admin/edit.php?post_type=portfolio-awesome6.1069.91
Categories /wp-admin/edit-tags.php?taxonomy=portfolio-category&post_type=portfolio-awesome6.0860.16
Showcase /wp-admin/edit.php?post_type=showcase-awesome6.1060.40

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 612 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

Portfolio Awesome - Responsive WordPress Porfolio Plugin: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,235 ▲47418.92 ▲4.636.13 ▲4.2335.75 ▼9.46
Dashboard /wp-admin2,551 ▲3489.32 ▲3.43185.80 ▲77.7340.88 ▼5.34
Posts /wp-admin/edit.php2,469 ▲3696.32 ▲4.1588.09 ▲49.8434.94 ▲0.32
Add New Post /wp-admin/post-new.php6,288 ▲4,74323.00 ▼0.16971.30 ▲293.9752.82 ▼3.44
Media Library /wp-admin/upload.php1,600 ▲2096.77 ▲2.58112.08 ▲2.1243.97 ▼1.71
Settings /wp-admin/crb_carbon_fields_container_portfolio_awesome_general_setting.php260.440.0718.30
Add New Portfolio /wp-admin/post-new.php?post_type=portfolio-awesome1,68318.621,000.0141.40
Portfolio Item /wp-admin/edit.php?post_type=portfolio-awesome1,4496.3087.8831.96
Categories /wp-admin/edit-tags.php?taxonomy=portfolio-category&post_type=portfolio-awesome1,6816.2076.6930.82
Showcase /wp-admin/edit.php?post_type=showcase-awesome1,4336.1689.2630.95

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 detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=portfolio-awesome
    • > User deprecated in wp-includes/functions.php+5828
    Hook block_categories is deprecated since version 5.8.0! Use block_categories_all instead.

SRP 0% 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
  • 3× PHP files output text when accessed directly:
    • > /wp-content/plugins/portfolio-builder-awesome/public/partials/wrap-start.php
    • > /wp-content/plugins/portfolio-builder-awesome/public/partials/wrap-end.php
    • > /wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
  • 149× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Condition' not found in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/core/Container/Condition/Post_Template_Condition.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Field' not found in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/core/Field/Complex_Field.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_style() in wp-content/plugins/portfolio-builder-awesome/gutenberg-blocks/portfolio-block.php:9
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/templates/Container/comment_meta.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Term_Condition' not found in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/core/Container/Condition/Term_Parent_Condition.php:28
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/templates/Container/post_meta.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/portfolio-builder-awesome/public/portfolio-styles/masonry-full-image-1.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Field' not found in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/core/Field/Separator_Field.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Query' not found in wp-content/plugins/portfolio-builder-awesome/elementor-widgets/portfolios/tpl/portfolio-block.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Condition' not found in wp-content/plugins/portfolio-builder-awesome/vendor/htmlburger/carbon-fields/core/Container/Condition/Post_Type_Condition.php:8

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There are user-side issues you should fix
    • > GET request to /wp-admin/crb_carbon_fields_container_portfolio_awesome_general_setting.php
    • > Network (severe)
    wp-admin/crb_carbon_fields_container_portfolio_awesome_general_setting.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/post-new.php?post_type=portfolio-awesome
    • > Console-api (warning) in wp-includes/js/dist/deprecated.min.js?ver=73ad3591e7bc95f4777a+1:627
    wp.compose.withState is deprecated since version 5.8. Please use wp.element.useState instead.

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: showcase, portfolio, gallery, grid, project

portfolio-builder-awesome/portfolio-awesome.php 85% from 13 tests

The main PHP script in "Portfolio Awesome - Responsive WordPress Porfolio Plugin" version 1.1.0 is automatically included on every request by WordPress
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 ("portfolio-builder-awesome.php" instead of "portfolio-awesome.php")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

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
There were no executable files found in this plugin56,395 lines of code in 504 files:
LanguageFilesBlank linesComment linesLines of code
CSS203,7761,75519,506
PHP1973,7757,49916,738
JavaScript1955,5239,11415,493
Sass5136701,936
PO File216147831,673
JSON1200797
Markdown6520162
SVG20090

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity8.23
▷ Minimum class complexity1.00
▷ Maximum class complexity50.00
Average method complexity2.09
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces27
Interfaces6
Traits0
Classes140
▷ Abstract classes117.86%
▷ Concrete classes12992.14%
▷ Final classes10.78%
Methods982
▷ Static methods10410.59%
▷ Public methods80081.47%
▷ Protected methods16917.21%
▷ Private methods131.32%
Functions231
▷ Named functions14060.61%
▷ Anonymous functions9139.39%
Constants39
▷ Global constants1435.90%
▷ Class constants2564.10%
▷ Public constants25100.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
12 PNG files occupy 0.12MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/slide.png6.15KB2.64KB▼ 57.01%
public/img/vertical-8.png0.11KB0.11KB▼ 0.85%
assets/carousel.png6.71KB2.85KB▼ 57.54%
assets/justified.png6.92KB3.03KB▼ 56.15%
assets/grid.png6.45KB2.93KB▼ 54.61%