84% fanpage-embed

Code Review | Embed Fanpage Widget

WordPress plugin Embed Fanpage Widget scored 84% from 54 tests.

About plugin

  • Plugin page: fanpage-embed
  • Plugin version: 1.0
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.3
  • WordPress version: 5.8.1
  • First release: Jan 1, 2020
  • Latest release: Jan 2, 2020
  • Number of updates: 4
  • Update frequency: every 0.5 days
  • Top authors: chuanw3s (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 362 total downloads


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
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼141.84ms] Passed 4 tests

An overview of server-side resources used by Embed Fanpage Widget
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.86 ▲0.1437.36 ▲5.74
Dashboard /wp-admin3.08 ▲0.0359.04 ▼0.37
Posts /wp-admin/edit.php3.14 ▲0.0357.41 ▲9.43
Add New Post /wp-admin/post-new.php5.44 ▲0.01107.88 ▼569.45
Media Library /wp-admin/upload.php3.03 ▲0.0237.20 ▼3.26

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 1 new option
New WordPress options

Browser metrics Passed 4 tests

Embed Fanpage Widget: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,715 ▲14316.63 ▲0.7430.87 ▲22.1554.31 ▼0.32
Dashboard /wp-admin2,986 ▲556.06 ▲0.07159.05 ▼18.11126.87 ▲1.83
Posts /wp-admin/edit.php2,739 ▼02.71 ▲0.0093.66 ▲1.27101.99 ▲2.11
Add New Post /wp-admin/post-new.php1,683 ▲10218.28 ▼2.99446.04 ▲8.42114.65 ▼10.13
Media Library /wp-admin/upload.php1,807 ▼35.05 ▲0.01174.15 ▲8.43131.62 ▲3.56

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The uninstall procedure has failed, leaving 1 option in the database
    • widget_id-c3fanpage

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 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
Almost there! Just fix the following items
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/fanpage-embed/w3sfanpage.php
    • > /wp-content/plugins/fanpage-embed/widget.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side


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
No tags were found

fanpage-embed/w3sfanpage.php 92% from 13 tests

The principal PHP file in "Embed Fanpage Widget" v. 1.0 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("fanpage-embed.php" instead of "w3sfanpage.php")

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
Everything looks great! No dangerous files found in this plugin86 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.61
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity3.25
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions00.00%
▷ Anonymous functions2100.00%
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
There were not PNG files found in your plugin