10% juiz-last-tweet-widget

Code Review | Juiz Last Tweet Widget

WordPress plugin Juiz Last Tweet Widget scored10%from 54 tests.

About plugin

  • Plugin page: juiz-last-tweet-w...
  • Plugin version: 1.3.7
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.5.1
  • WordPress version: 6.3.1
  • First release: Jan 5, 2012
  • Latest release: Sep 22, 2020
  • Number of updates: 62
  • Update frequency: every 51.3 days
  • Top authors: CreativeJuiz (100%)

Code review

54 tests

User reviews

26 reviews

Install metrics

1,000+ active /99,270 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
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/juiz-last-tweet-widget/juiz-last-tweet.php+624
    Function create_function() is deprecated

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

This is a short check of server-side resources used by Juiz Last Tweet Widget
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.38 ▼1.119.33 ▼33.26
Dashboard /wp-admin2.40 ▼0.9410.66 ▼42.19
Posts /wp-admin/edit.php2.40 ▼0.999.72 ▼39.30
Add New Post /wp-admin/post-new.php2.40 ▼3.529.86 ▼82.15
Media Library /wp-admin/upload.php2.40 ▼0.8610.63 ▼24.13
Last Tweet Widget /wp-admin/options-general.php?page=juiz-last-tweet-widget2.4010.47

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 53 new files
Database: no new tables, 8 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_juiz_last_tweet_widget
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
juiz_ltw_settings

Browser metrics Passed 4 tests

Checking browser requirements for Juiz Last Tweet Widget
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7913.20 ▼1.581.56 ▼0.2940.88 ▼5.17
Dashboard /wp-admin2,222 ▲344.86 ▼0.06107.63 ▼6.5545.61 ▲1.50
Posts /wp-admin/edit.php2,104 ▲122.03 ▲0.0239.76 ▲4.1533.32 ▲0.76
Add New Post /wp-admin/post-new.php1,560 ▲2118.32 ▼4.91652.67 ▲3.4450.92 ▼7.51
Media Library /wp-admin/upload.php1,404 ▲134.22 ▲0.02109.58 ▲15.4248.51 ▲7.08
Last Tweet Widget /wp-admin/options-general.php?page=juiz-last-tweet-widget1,1081.8131.9243.13

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/juiz-last-tweet-widget/juiz-last-tweet.php+624
    Function create_function() is deprecated
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=juiz-last-tweet-widget
    • > Deprecated in wp-content/plugins/juiz-last-tweet-widget/juiz-last-tweet.php+624
    Function create_function() is deprecated

SRP 0% 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
The following issues need your attention
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/juiz-last-tweet-widget/admin/jltw-admin-styles-scripts.php
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/juiz-last-tweet-widget/admin/jltw-admin.inc.php:9
    • > PHP Warning
      Use of undefined constant JUIZ_LTW_PLUGIN_NAME - assumed 'JUIZ_LTW_PLUGIN_NAME' (this will throw an Error in a future version of PHP) in wp-content/plugins/juiz-last-tweet-widget/admin/jltw-admin-styles-scripts.php on line 64
    • > PHP Warning
      Use of undefined constant JUIZ_LTW_PLUGIN_NAME - assumed 'JUIZ_LTW_PLUGIN_NAME' (this will throw an Error in a future version of PHP) in wp-content/plugins/juiz-last-tweet-widget/admin/jltw-admin-styles-scripts.php on line 2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/juiz-last-tweet-widget/juiz-last-tweet.php:39

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 90% 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:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Juiz Last Tweet in action (french interface)), #2 (Juiz Last Tweet in the admin (Widget view)), #3 (Juiz Last Tweet with avatar displayed and custom CSS), #4 (Juiz Last Tweet with avatar and action links displayed), #5 (An example of custom styles), #6 (The new admin page for 1.2.0 (translators are welcome :p)), #7 (The new color picker feature!)
The official readme.txt is a good inspiration

juiz-last-tweet-widget/juiz-last-tweet.php 85% from 13 tests

"Juiz Last Tweet Widget" version 1.3.7's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("juiz-last-tweet-widget.php" instead of "juiz-last-tweet.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 389 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin4,055 lines of code in 23 files:
LanguageFilesBlank linesComment linesLines of code
PHP54024301,587
PO File95647271,463
HTML21193561
JavaScript36090317
CSS4118127

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity12.38
▷ Minimum class complexity1.00
▷ Maximum class complexity59.00
Average method complexity2.72
▷ Minimum method complexity1.00
▷ Maximum method complexity37.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes13
▷ Abstract classes215.38%
▷ Concrete classes1184.62%
▷ Final classes00.00%
Methods86
▷ Static methods1011.63%
▷ Public methods7587.21%
▷ Protected methods22.33%
▷ Private methods910.47%
Functions30
▷ Named functions30100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.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
15 compressed PNG files occupy 0.12MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-6.png22.96KB23.39KB0.00%
screenshot-1.png7.33KB6.10KB▼ 16.77%
admin/js/color-picker/mask.png1.97KB4.18KB0.00%
admin/js/color-picker/wheel.png11.46KB6.53KB▼ 43.01%
admin/js/color-picker/marker.png0.64KB0.71KB0.00%