83% prodii-presentation-for-teams-and-organisations

Code Review | Prodii Presentation - for Teams and Organisations

WordPress plugin Prodii Presentation - for Teams and Organisations scored83%from 54 tests.

About plugin

  • Plugin page: prodii-presentati...
  • Plugin version: 0.1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.6-4.9.6
  • WordPress version: 6.3.1
  • First release: Aug 10, 2018
  • Latest release: Aug 10, 2018
  • Number of updates: 3
  • Update frequency: every 9.7 days
  • Top authors: prodii (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /505 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▲2.93ms] 75% from 4 tests

Analyzing server-side resources used by Prodii Presentation - for Teams and Organisations
It is recommended to improve the following
  • CPU: Try to keep total CPU usage under 500.00ms (currently 604.64ms on /wp-admin/admin.php?page=prodii-settings)
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0345.87 ▲6.76
Dashboard /wp-admin3.34 ▲0.0346.24 ▲0.74
Posts /wp-admin/edit.php3.45 ▲0.0946.95 ▲4.09
Add New Post /wp-admin/post-new.php5.92 ▲0.0391.80 ▲6.29
Media Library /wp-admin/upload.php3.26 ▲0.0332.98 ▲0.61
Reference /wp-admin/admin.php?page=prodii-reference3.3132.28
Shortcodes /wp-admin/admin.php?page=prodii-overview3.301,302.13
Settings /wp-admin/admin.php?page=prodii-settings3.30604.64

Server storage [IO: ▲1.48MB] [DB: ▲0.00MB] 67% from 3 tests

Filesystem and database footprint
Please try to fix the following items
  • Illegal file modification found: 7 files (0.43KB) outside of "wp-content/plugins/prodii-presentation-for-teams-and-organisations/" and "wp-content/uploads/"
    • (new file) wp-content/cache/prodii/curl/1e1ec1b8477dea71d0ae4f3eca36b68a1ed26d87e9d327e05713f25b1526ef65
    • (new file) wp-content/cache/prodii/curl/6d4bc4492e754ef823b5e3073270d24c49434302bf8f1df7c053494a0daf26af
    • (new file) wp-content/cache/prodii/profile/.empty
    • (new file) wp-content/cache/prodii/company/.empty
    • (new file) wp-content/cache/prodii/team/.empty
    • (new file) wp-content/cache/prodii/curl/6f7ef0c9168af37afdd41d9261cd15c578264ac4b0d55b45474fbbb26ab7b7a0
    • (new file) wp-content/cache/prodii/curl/0c8034005077ca82f556e3c21fa42fd77105fc56588da9f955781a96ea871475
Filesystem: 51 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

Prodii Presentation - for Teams and Organisations: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲9114.41 ▲0.051.81 ▼0.2642.19 ▼5.02
Dashboard /wp-admin2,235 ▲445.90 ▲1.0196.27 ▼3.6589.27 ▲44.96
Posts /wp-admin/edit.php2,121 ▲352.00 ▼0.0437.31 ▲0.7332.73 ▲0.18
Add New Post /wp-admin/post-new.php1,545 ▲1218.09 ▼5.10735.81 ▲108.3666.21 ▲16.26
Media Library /wp-admin/upload.php1,414 ▲264.22 ▲0.05101.93 ▲3.9787.15 ▲39.10
Reference /wp-admin/admin.php?page=prodii-reference1,6082.1837.7252.94
Shortcodes /wp-admin/admin.php?page=prodii-overview9841.9026.3328.93
Settings /wp-admin/admin.php?page=prodii-settings1,0071.9524.7529.88

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% 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 did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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
  • 13× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'ProdiiBase' not found in wp-content/plugins/prodii-presentation-for-teams-and-organisations/classes/ProdiiCompany.php:23
    • > PHP Fatal error
      Uncaught Error: Call to undefined function prodii_template_data() in wp-content/plugins/prodii-presentation-for-teams-and-organisations/prodii-templates/copenhagen/tmp/template-team.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'ProdiiBase' not found in wp-content/plugins/prodii-presentation-for-teams-and-organisations/pages/page-settings.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/prodii-presentation-for-teams-and-organisations/classes/ProdiiShortcode.php:122
    • > PHP Fatal error
      Uncaught Error: Class 'ProdiiBase' not found in wp-content/plugins/prodii-presentation-for-teams-and-organisations/classes/ProdiiList.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ProdiiBase' not found in wp-content/plugins/prodii-presentation-for-teams-and-organisations/classes/ProdiiProfile.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Prodii' not found in wp-content/plugins/prodii-presentation-for-teams-and-organisations/pages/page-reference.php:23
    • > PHP Fatal error
      Uncaught Error: Call to undefined function prodii_template_data() in wp-content/plugins/prodii-presentation-for-teams-and-organisations/prodii-templates/copenhagen/tmp/template-team-multi.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/prodii-presentation-for-teams-and-organisations/setup.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/prodii-presentation-for-teams-and-organisations/classes/ProdiiAjax.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: presentation, teams, api, remote, prodii

prodii-presentation-for-teams-and-organisations/setup.php 77% from 13 tests

"Prodii Presentation - for Teams and Organisations" version 0.1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Domain Path: The domain path folder does not exist ("/prodii-presentation")
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("prodii-presentation-for-teams-and-organisations.php" instead of "setup.php")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

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
Success! There were no dangerous files found in this plugin11,117 lines of code in 41 files:
LanguageFilesBlank linesComment linesLines of code
CSS5287203,555
JavaScript92572092,681
SVG1002,671
PHP213043461,967
Sass4350219
JSON10024

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity17.73
▷ Minimum class complexity1.00
▷ Maximum class complexity40.00
Average method complexity2.83
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes19.09%
Methods97
▷ Static methods4748.45%
▷ Public methods7779.38%
▷ Protected methods44.12%
▷ Private methods1616.49%
Functions22
▷ Named functions940.91%
▷ Anonymous functions1359.09%
Constants5
▷ Global constants240.00%
▷ Class constants360.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/prodii.png1.13KB0.24KB▼ 78.76%
prodii-templates/copenhagen/assets/img/placeholder-310x310.png4.17KB2.48KB▼ 40.52%
assets/img/settings.png20.82KB7.92KB▼ 61.96%