84% news-ticker-by-minhaj

Code Review | News Ticker by minhaj

WordPress plugin News Ticker by minhaj scored84%from 54 tests.

About plugin

  • Plugin page: news-ticker-by-mi...
  • Plugin version: 1.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7
  • WordPress version: 6.3.1
  • First release: Feb 22, 2018
  • Latest release: Feb 23, 2018
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: minhazur (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /536 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.67ms] Passed 4 tests

An overview of server-side resources used by News Ticker by minhaj
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.74 ▼3.00
Dashboard /wp-admin3.32 ▲0.0147.35 ▼6.13
Posts /wp-admin/edit.php3.37 ▲0.0147.09 ▲0.79
Add New Post /wp-admin/post-new.php5.90 ▲0.0192.38 ▼8.75
Media Library /wp-admin/upload.php3.24 ▲0.0134.36 ▼0.78

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by News Ticker by minhaj
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,883 ▲13713.57 ▼0.744.92 ▲3.2441.78 ▼3.89
Dashboard /wp-admin2,209 ▲184.86 ▼0.0599.63 ▼3.6539.26 ▼0.87
Posts /wp-admin/edit.php2,089 ▼02.02 ▲0.0238.59 ▼0.1834.21 ▲1.61
Add New Post /wp-admin/post-new.php1,542 ▲2818.35 ▲0.79640.75 ▲3.5758.63 ▲0.58
Media Library /wp-admin/upload.php1,382 ▼34.20 ▼0.0197.18 ▼4.5442.57 ▼3.63

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
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/news-ticker-by-minhaj/news_ticker.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
5 plugin tags: news headlines, headlines, news ticker, newsfeed, random news

news-ticker-by-minhaj/news_ticker.php 85% from 13 tests

This is the main PHP file of "News Ticker by minhaj" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("news-ticker-by-minhaj.php" instead of "news_ticker.php")
  • Description: Keep the plugin description shorter than 140 characters (currently 146 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin58 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP131850
CSS1007
JavaScript1011

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.06
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%
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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/icon.png1.63KB0.66KB▼ 59.70%