78% rs-twitter-follow-popup

Code Review | RS Twitter Follow Popup

WordPress plugin RS Twitter Follow Popup scored78%from 54 tests.

About plugin

  • Plugin page: rs-twitter-follow...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.8.2
  • WordPress version: 6.3.1
  • First release: Apr 21, 2016
  • Latest release: Apr 21, 2016
  • Number of updates: 5
  • Update frequency: every 105.6 days
  • Top authors: rosinghal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /673 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼7.08ms] Passed 4 tests

Server-side resources used by RS Twitter Follow Popup
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0736.86 ▼6.13
Dashboard /wp-admin3.37 ▲0.0750.17 ▼0.62
Posts /wp-admin/edit.php3.48 ▲0.1351.47 ▲2.11
Add New Post /wp-admin/post-new.php5.97 ▲0.0881.20 ▼16.22
Media Library /wp-admin/upload.php3.29 ▲0.0637.85 ▼5.34
RS Twitter Follow Popup /wp-admin/options-general.php?page=rs-twitter-follow-popup3.2537.56

Server storage [IO: ▲0.06MB] [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: 22 new files
Database: no new tables, 9 new options
New WordPress options
widget_recent-comments
widget_recent-posts
twitter_page
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
popup_show_after
twitter_widget_id
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for RS Twitter Follow Popup
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,880 ▲11913.50 ▼1.0510.95 ▲9.0140.18 ▼6.56
Dashboard /wp-admin2,206 ▲425.58 ▼0.0797.34 ▼17.7336.67 ▼6.10
Posts /wp-admin/edit.php2,108 ▲82.01 ▲0.0039.46 ▼0.0935.54 ▼1.70
Add New Post /wp-admin/post-new.php1,535 ▲923.17 ▲0.08675.25 ▼14.2956.64 ▲4.87
Media Library /wp-admin/upload.php1,405 ▲84.20 ▲0.05101.47 ▼14.4847.05 ▼2.07
RS Twitter Follow Popup /wp-admin/options-general.php?page=rs-twitter-follow-popup8442.0326.0928.56

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Zombie WordPress options were found after uninstall: 9 options
    • widget_recent-posts
    • twitter_widget_id
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • twitter_page
    • theysaidso_admin_options
    • popup_show_after

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=rs-twitter-follow-popup
    • > Notice in wp-content/plugins/rs-twitter-follow-popup/admin/partials/rs-twitter-follow-popup-admin-display.php+28
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/rs-twitter-follow-popup/admin/partials/rs-twitter-follow-popup-admin-display.php:18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/rs-twitter-follow-popup/public/partials/rs-twitter-follow-popup-public-display.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
  • Plugin Name: Please specify the plugin name on the first line ( === rs-twitter-follow-popup === )
You can take inspiration from this readme.txt

rs-twitter-follow-popup/rs-twitter-follow-popup.php Passed 13 tests

The main PHP file in "RS Twitter Follow Popup" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
66 characters long description:
Increase your twitter followers with this simple Wordpress plugin.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin297 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP12155577288
JavaScript26628
CSS20111

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity2.57
▷ Minimum class complexity1.00
▷ Maximum class complexity9.00
Average method complexity1.38
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods29
▷ Static methods26.90%
▷ Public methods2482.76%
▷ Protected methods00.00%
▷ Private methods517.24%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin