84% tweeple

Code Review | Tweeple

WordPress plugin Tweeple scored84%from 54 tests.

About plugin

  • Plugin page: tweeple
  • Plugin version: 0.9.5
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jun 18, 2013
  • Latest release: Apr 5, 2018
  • Number of updates: 46
  • Update frequency: every 38.1 days
  • Top authors: themeblvd (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

2,000+ active /70,182 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.47MB] [CPU: ▼1.53ms] Passed 4 tests

Analyzing server-side resources used by Tweeple
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.94 ▲0.4742.55 ▲2.65
Dashboard /wp-admin3.82 ▲0.5150.24 ▲0.05
Posts /wp-admin/edit.php3.87 ▲0.5152.55 ▲4.81
Add New Post /wp-admin/post-new.php6.33 ▲0.4488.13 ▼13.63
Media Library /wp-admin/upload.php3.68 ▲0.4439.61 ▲5.60
Tweeple /wp-admin/tools.php?page=tweeple3.6535.83

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 23 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
db_upgraded
tweeple_plugin_version
widget_recent-posts
widget_tweeple_feed_widget
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

Tweeple: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.21 ▼0.141.71 ▼0.0141.58 ▼4.65
Dashboard /wp-admin2,202 ▲285.67 ▲0.0990.26 ▼8.2442.65 ▼0.74
Posts /wp-admin/edit.php2,104 ▲42.01 ▲0.0135.71 ▼3.6539.72 ▲1.96
Add New Post /wp-admin/post-new.php1,529 ▲123.37 ▲0.10661.77 ▼22.0151.12 ▲0.44
Media Library /wp-admin/upload.php1,398 ▼24.20 ▼0.00100.66 ▼9.2743.51 ▼4.77
Tweeple /wp-admin/tools.php?page=tweeple8692.0727.5327.07

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 8 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_tweeple_feed_widget
    • widget_theysaidso_widget
    • tweeple_plugin_version
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/tweeple/inc/class-tweeple-feed-widget.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/tweeple/tweeple.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
10 plugin tags: status, twitter, tweets, theme blvd, tmhoauth...

tweeple/tweeple.php Passed 13 tests

The main file in "Tweeple" v. 0.9.5 serves as a complement to information provided in readme.txt and as the entry point to the plugin
128 characters long description:
Setup Twitter feeds to pull a user's public timeline, public list, favorite tweets, or a custom search term, phrase, or hashtag.

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
Success! There were no dangerous files found in this plugin2,713 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP96609502,180
PO File1125139271
CSS156136
JavaScript1241950
Markdown123050
JSON10026

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity41.43
▷ Minimum class complexity8.00
▷ Maximum class complexity93.00
Average method complexity4.49
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods81
▷ Static methods1113.58%
▷ Public methods5871.60%
▷ Protected methods00.00%
▷ Private methods2328.40%
Functions20
▷ Named functions20100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
6 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/icon-refresh_2x.png2.61KB1.50KB▼ 42.51%
assets/images/icon-refresh.png1.67KB0.98KB▼ 41.39%
assets/images/icon_2x.png3.88KB2.24KB▼ 42.11%
assets/images/icon-delete_2x.png2.92KB1.73KB▼ 40.92%
assets/images/icon.png2.38KB1.51KB▼ 36.65%