84% fancy-news

Code Review | Fancy News

WordPress plugin Fancy News scored84%from 54 tests.

About plugin

  • Plugin page: fancy-news
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.8
  • WordPress version: 6.3.1
  • First release: Jun 1, 2018
  • Latest release: Jun 2, 2018
  • Number of updates: 9
  • Update frequency: every 0.1 days
  • Top authors: webradykal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /1,474 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.05MB] [CPU: ▼2.34ms] Passed 4 tests

An overview of server-side resources used by Fancy News
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0445.05 ▲0.78
Dashboard /wp-admin3.36 ▲0.0555.13 ▲0.79
Posts /wp-admin/edit.php3.47 ▲0.1153.95 ▼1.35
Add New Post /wp-admin/post-new.php5.94 ▲0.0592.16 ▼9.14
Media Library /wp-admin/upload.php3.28 ▲0.0540.35 ▲0.35

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Fancy News: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲6213.18 ▼1.101.83 ▼0.3842.42 ▼7.01
Dashboard /wp-admin2,225 ▲224.88 ▼1.00119.71 ▲5.3944.00 ▲0.65
Posts /wp-admin/edit.php2,107 ▲71.98 ▼0.0142.96 ▼0.7135.66 ▼1.77
Add New Post /wp-admin/post-new.php1,548 ▲323.11 ▼0.07656.84 ▼25.2886.14 ▲8.58
Media Library /wp-admin/upload.php1,404 ▲44.15 ▼0.10112.38 ▲3.0648.69 ▲3.32

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options

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
Even though everything seems fine, this is not an exhaustive test

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 take a closer look at the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/fancy-news/admin/admin-page.php:2

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 Passed 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
6 plugin tags: widget, post slider, rss feed, news slider, reader...

fancy-news/fancy-news.php Passed 13 tests

"Fancy News" version 1.1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
41 characters long description:
Add any post type to a Fancy News slider.

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
No dangerous file extensions were detected4,539 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript33432582,569
CSS58356826
PHP213625475
SVG100414
PO File2104104255

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.12
Average class complexity15.00
▷ Minimum class complexity15.00
▷ Maximum class complexity15.00
Average method complexity2.27
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants125.00%
▷ Class constants375.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

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