10% wptwitterwidget

Code Review | WP Twitter Plugin

WordPress plugin WP Twitter Plugin scored10%from 54 tests.

About plugin

  • Plugin page: wptwitterwidget
  • Plugin version: 1.02
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.8.1
  • WordPress version: 6.3.1
  • First release: Mar 19, 2014
  • Latest release: Mar 19, 2014
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: wptwitterplugin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,373 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
It is recommended to fix the following installer errors
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/wptwitterwidget/index.php+11
    Methods with the same name as their class will not be constructors in a future version of PHP; wptwitterplugin_Widget has a deprecated constructor

Server metrics [RAM: ▼1.92MB] [CPU: ▼57.65ms] Passed 4 tests

Analyzing server-side resources used by WP Twitter Plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.394.54 ▼34.73
Dashboard /wp-admin2.10 ▼1.256.51 ▼59.33
Posts /wp-admin/edit.php2.10 ▼1.266.68 ▼41.07
Add New Post /wp-admin/post-new.php2.10 ▼3.795.28 ▼95.47
Media Library /wp-admin/upload.php2.10 ▼1.135.18 ▼32.82

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
widget_wptwitterplugin-widget
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by WP Twitter Plugin
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.30 ▲0.071.71 ▲0.0244.51 ▲0.84
Dashboard /wp-admin2,195 ▲155.62 ▼0.0790.33 ▼9.9539.32 ▼4.70
Posts /wp-admin/edit.php2,100 ▲32.02 ▼0.0036.22 ▼2.1035.93 ▼0.94
Add New Post /wp-admin/post-new.php1,550 ▲1923.13 ▼0.12628.37 ▼53.6458.53 ▲4.83
Media Library /wp-admin/upload.php1,400 ▼04.24 ▼0.0498.49 ▼16.7340.32 ▼6.80

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/wptwitterwidget/index.php+11
    Methods with the same name as their class will not be constructors in a future version of PHP; wptwitterplugin_Widget has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • widget_wptwitterplugin-widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wptwitterwidget/index.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: widget, twitter, plugin, simple

wptwitterwidget/index.php 92% from 13 tests

"WP Twitter Plugin" version 1.02's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wptwitterwidget.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin45 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP10945

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity1.83
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin