78% facebook-secret-meta

Code Review | Secret Meta

WordPress plugin Secret Meta scored78%from 54 tests.

About plugin

  • Plugin page: facebook-secret-meta
  • Plugin version: 1.2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 2.5.0-5.2
  • WordPress version: 6.3.1
  • First release: Apr 30, 2014
  • Latest release: Jul 15, 2019
  • Number of updates: 29
  • Update frequency: every 65.6 days
  • Top authors: Asif2BD (86.21%)onetarek (17.24%)

Code review

54 tests

User reviews

2 reviews

Install metrics

30+ active /4,469 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼1.64ms] Passed 4 tests

An overview of server-side resources used by Secret Meta
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0342.07 ▲0.36
Dashboard /wp-admin4.28 ▲0.9751.27 ▼2.13
Posts /wp-admin/edit.php3.39 ▲0.0343.44 ▼5.88
Add New Post /wp-admin/post-new.php5.92 ▲0.0390.82 ▲1.32
Media Library /wp-admin/upload.php3.26 ▲0.0338.61 ▲1.09
Facebook Secret Meta /wp-admin/options-general.php?page=facebook-secret-meta4.1137.82

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Secret Meta
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,885 ▲12414.28 ▲0.072.18 ▲0.2042.67 ▲5.00
Dashboard /wp-admin2,285 ▲1055.63 ▼0.0786.34 ▼4.7352.96 ▲12.88
Posts /wp-admin/edit.php2,115 ▲151.98 ▲0.0237.39 ▲2.1135.14 ▼2.20
Add New Post /wp-admin/post-new.php1,549 ▲1218.02 ▼4.92643.58 ▼7.0465.86 ▲14.44
Media Library /wp-admin/upload.php1,418 ▲184.36 ▲0.30109.09 ▼7.1349.66 ▼3.20
Facebook Secret Meta /wp-admin/options-general.php?page=facebook-secret-meta1,4484.67101.0080.92

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 8× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/facebook-secret-meta/facebook-secret-meta.php:17
    • > PHP Warning
      Use of undefined constant WPINC - assumed 'WPINC' (this will throw an Error in a future version of PHP) in wp-content/plugins/facebook-secret-meta/wpdev-dashboard-widget.php on line 5
    • > PHP Warning
      include_once(ABSPATHWPINC/feed.php): failed to open stream: No such file or directory in wp-content/plugins/facebook-secret-meta/wpdev-dashboard-widget.php on line 5
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/facebook-secret-meta/wpdev-dashboard-widget.php on line 5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wpdev_dashboard_widget_function() in wp-content/plugins/facebook-secret-meta/fbsm-sidebar.php:122
    • > PHP Warning
      Use of undefined constant FBSM_PLUGIN_URL - assumed 'FBSM_PLUGIN_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/facebook-secret-meta/fbsm-sidebar.php on line 2
    • > PHP Warning
      include_once(): Failed opening 'ABSPATHWPINC/feed.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/facebook-secret-meta/wpdev-dashboard-widget.php on line 5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/facebook-secret-meta/wpdev-dashboard-widget.php:50

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=facebook-secret-meta
    • > Security (warning) in unknown
    security - Error with Permissions-Policy header: Unrecognized feature: 'ambient-light-sensor'.
    • > GET request to /wp-admin/options-general.php?page=facebook-secret-meta
    • > Security (warning) in unknown
    security - Error with Permissions-Policy header: Unrecognized feature: 'bluetooth'.

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Tags: You are using too many tags: 12 tag instead of maximum 10
You can take inspiration from this readme.txt

facebook-secret-meta/facebook-secret-meta.php Passed 13 tests

The entry point to "Secret Meta" version 1.2.1 is a PHP file that has certain tags in its header comment area
86 characters long description:
Only this Secret Meta plugin enables Facebook's brand-new Author By info at News Feed.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin310 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP423026310

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.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
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
wpdeveloper-logo-2.png15.28KB5.27KB▼ 65.52%