63% wd-facebook-feed

Code Review | 10Web Social Post Feed

WordPress plugin 10Web Social Post Feed scored 63% from 54 tests.

About plugin

  • Plugin page: wd-facebook-feed
  • Plugin version: 1.2.9
  • PHP compatiblity: 5.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4-5.0
  • WordPress version: 6.3.1
  • First release: May 26, 2016
  • Latest release: May 10, 2023
  • Number of updates: 210
  • Update frequency: every 12.1 days
  • Top authors: webdorado (59.05%)10web (41.43%)

Code review

54 tests

User reviews

213 reviews

Install metrics

20,000+ active / 1,345,669 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▲1.52ms] Passed 4 tests

Analyzing server-side resources used by 10Web Social Post Feed
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1341.49 ▼10.45
Dashboard /wp-admin3.43 ▲0.1352.05 ▲6.49
Posts /wp-admin/edit.php3.55 ▲0.1955.78 ▲5.70
Add New Post /wp-admin/post-new.php5.98 ▲0.10103.43 ▲4.35
Media Library /wp-admin/upload.php3.36 ▲0.1342.45 ▲10.39
Uninstall /wp-admin/admin.php?page=uninstall_ffwd3.6440.83
Speed & Image Optimization /wp-admin/admin.php?page=twb_facebook-feed3.6241.43
Options /wp-admin/admin.php?page=options_ffwd3.4042.19

Server storage [IO: ▲5.65MB] [DB: ▲0.05MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 412 new files
Database: 5 new tables, 12 new options
New tables
wp_wd_fb_theme
wp_wd_fb_info
wp_wd_fb_shortcode
wp_wd_fb_data
wp_wd_fb_option
New WordPress options
ffwd_old_version
twb_images_total_size
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
ffwd_autoupdate_time
widget_ffwd_info
widget_theysaidso_widget
ffwd_admin_notice
can_compress_scripts
...

Browser metrics Passed 4 tests

10Web Social Post Feed: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,549 ▲80314.51 ▼0.2532.64 ▲30.7537.95 ▼4.96
Dashboard /wp-admin2,247 ▲594.93 ▲0.04101.77 ▼6.8873.32 ▲35.50
Posts /wp-admin/edit.php2,807 ▲7182.62 ▲0.6073.16 ▲30.7446.15 ▲8.52
Add New Post /wp-admin/post-new.php6,485 ▲4,94320.92 ▲2.70867.83 ▲257.3139.35 ▼16.85
Media Library /wp-admin/upload.php1,438 ▲504.38 ▲0.1597.44 ▲0.1264.06 ▲19.90
Uninstall /wp-admin/admin.php?page=uninstall_ffwd9341.8326.3132.92
Speed & Image Optimization /wp-admin/admin.php?page=twb_facebook-feed1,1851.8833.7863.35
Options /wp-admin/admin.php?page=options_ffwd1,2292.0832.1991.08

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • The uninstall procedure failed, leaving 5 tables in the database
    • wp_wd_fb_info
    • wp_wd_fb_data
    • wp_wd_fb_shortcode
    • wp_wd_fb_option
    • wp_wd_fb_theme
  • This plugin does not fully uninstall, leaving 12 options in the database
    • twb_images_total_size
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • ffwd_autoupdate_time
    • widget_ffwd_info
    • ffwd_version
    • theysaidso_admin_options
    • db_upgraded
    • ffwd_admin_notice
    • ...

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Almost there! Just fix the following items
  • 63× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Facebook\\HttpClients\\FacebookHttpClientInterface' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/HttpClients/FacebookCurlHttpClient.php:34
    • > PHP Fatal error
      Uncaught Error: Class 'Facebook\\Exceptions\\FacebookSDKException' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/Exceptions/FacebookAuthenticationException.php:31
    • > PHP Fatal error
      Uncaught Error: Class 'Facebook\\Helpers\\FacebookSignedRequestFromInputHelper' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/Helpers/FacebookJavaScriptHelper.php:31
    • > PHP Fatal error
      Uncaught Error: Class 'Facebook\\GraphNodes\\GraphNode' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/GraphNodes/GraphGroup.php:31
    • > PHP Fatal error
      Uncaught Error: Interface 'Facebook\\HttpClients\\FacebookHttpClientInterface' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/HttpClients/FacebookStreamHttpClient.php:29
    • > PHP Fatal error
      Uncaught Error: Class 'Facebook\\GraphNodes\\GraphNodeFactory' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/GraphNodes/GraphObjectFactory.php:34
    • > PHP Fatal error
      Uncaught Error: Interface 'Misd\\Linkify\\LinkifyInterface' not found in wp-content/plugins/wd-facebook-feed/framework/linkify/Linkify.php:17
    • > PHP Fatal error
      Uncaught Error: Interface 'Facebook\\PersistentData\\PersistentDataInterface' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/PersistentData/FacebookSessionPersistentDataHandler.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'Facebook\\GraphNodes\\GraphNode' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/GraphNodes/GraphPicture.php:31
    • > PHP Fatal error
      Uncaught Error: Class 'Facebook\\Exceptions\\FacebookSDKException' not found in wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/src/Facebook/Exceptions/FacebookClientException.php:31

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
You can take inspiration from this readme.txt

wd-facebook-feed/facebook-feed-wd.php 92% from 13 tests

The principal PHP file in "10Web Social Post Feed" v. 1.2.9 is loaded by WordPress automatically on each request
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wd-facebook-feed.php" instead of "facebook-feed-wd.php")

Code Analysis 3% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
These items require your attention
  • You should never include executable (binary) or otherwise dangerous files in your plugin
    • .crt - Security Certificate in Firefox, IE, Chrome, Safari
      • wp-content/plugins/wd-facebook-feed/framework/facebook-sdk/fb_ca_chain_bundle.crt
33,428 lines of code in 215 files:
LanguageFilesBlank linesComment linesLines of code
PHP1232,2947,13818,350
CSS206801006,724
JavaScript247989756,552
SVG42021,179
PO File2190301443
Markdown3530173
HTML1107

PHP code 50% from 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
These items need your attention
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 117)
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity18.86
▷ Minimum class complexity1.00
▷ Maximum class complexity538.00
Average method complexity3.42
▷ Minimum method complexity1.00
▷ Maximum method complexity117.00
Code structure
Namespaces12
Interfaces6
Traits1
Classes108
▷ Abstract classes21.85%
▷ Concrete classes10698.15%
▷ Final classes00.00%
Methods858
▷ Static methods9310.84%
▷ Public methods76489.04%
▷ Protected methods748.62%
▷ Private methods202.33%
Functions55
▷ Named functions4581.82%
▷ Anonymous functions1018.18%
Constants53
▷ Global constants1630.19%
▷ Class constants3769.81%
▷ Public constants37100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
162 PNG files occupy 2.71MB with 1.40MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/wd_fb_shortcode.png18.61KB1.16KB▼ 93.78%
css/images/ui-bg_glass_100_f6f6f6_1x400.png0.26KB0.12KB▼ 53.44%
images/plus.png1.20KB1.17KB▼ 2.92%
images/views/logo.png8.25KB4.60KB▼ 44.26%
images/ffwd/ffwd_views.png10.64KB3.91KB▼ 63.23%