84% fast-page-switch

Code Review | Fast Page Switch

WordPress plugin Fast Page Switch scored84%from 54 tests.

About plugin

  • Plugin page: fast-page-switch
  • Plugin version: 1.5.8
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-5.4
  • WordPress version: 6.3.1
  • First release: May 27, 2015
  • Latest release: Apr 3, 2020
  • Number of updates: 39
  • Update frequency: every 45.5 days
  • Top authors: marclarr (100%)

Code review

54 tests

User reviews

21 reviews

Install metrics

600+ active /10,992 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
Installer ran successfully

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

This is a short check of server-side resources used by Fast Page Switch
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0543.84 ▼2.87
Dashboard /wp-admin3.36 ▲0.0254.93 ▼11.47
Posts /wp-admin/edit.php3.42 ▲0.0648.12 ▼0.11
Add New Post /wp-admin/post-new.php5.98 ▲0.0994.04 ▼6.43
Media Library /wp-admin/upload.php3.29 ▲0.0642.23 ▲6.45

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 56 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Fast Page Switch
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.18 ▼0.211.64 ▼1.0542.97 ▼0.82
Dashboard /wp-admin2,199 ▲195.64 ▼0.0295.72 ▲2.3943.71 ▲3.13
Posts /wp-admin/edit.php2,104 ▲72.08 ▲0.0535.43 ▲0.5235.43 ▲0.53
Add New Post /wp-admin/post-new.php6,483 ▲4,94827.93 ▲9.661,066.37 ▲442.8767.60 ▼0.93
Media Library /wp-admin/upload.php1,404 ▲14.32 ▲0.15112.83 ▲12.9347.00 ▲0.63
Fast Page Switch /wp-admin/options-general.php?page=Fast Page Switch9062.0021.7926.27

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
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • 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 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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
Please fix the following
  • 1× 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/fast-page-switch/fps-admin.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === fast-page-switch === )
  • Tags: You are using too many tags: 13 tag instead of maximum 10
Please take inspiration from this readme.txt

fast-page-switch/fast-page-switch.php Passed 13 tests

The main PHP script in "Fast Page Switch" version 1.5.8 is automatically included on every request by WordPress
63 characters long description:
Save time switching between posts of any post-type in wp-admin.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin866 lines of code in 54 files:
LanguageFilesBlank linesComment linesLines of code
CSS2120420
PHP48093398
JavaScript48474848

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin