94% live-search-for-post

Code Review | Live search for post

WordPress plugin Live search for post scored 94% from 54 tests.

About plugin

  • Plugin page: live-search-for-post
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.3
  • WordPress version: 5.8.1
  • First release: Jan 1, 2020
  • Latest release: Jan 1, 2020
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: mehtashail (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 246 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Live search for post
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1334.40 ▲12.79
Dashboard /wp-admin3.07 ▲0.0144.06 ▲1.52
Posts /wp-admin/edit.php3.12 ▲0.0143.06 ▲2.67
Add New Post /wp-admin/post-new.php5.43 ▼0.0095.11 ▼556.36
Media Library /wp-admin/upload.php3.01 ▲0.0031.09 ▼9.51

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Live search for post
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,689 ▲9316.28 ▲0.837.92 ▼3.1847.04 ▲3.85
Dashboard /wp-admin2,975 ▲415.93 ▼0.20131.79 ▼7.85101.83 ▼11.33
Posts /wp-admin/edit.php2,741 ▲22.72 ▲0.0162.55 ▼5.3490.60 ▼0.26
Add New Post /wp-admin/post-new.php1,685 ▲1318.71 ▼0.16375.13 ▲8.29111.94 ▲0.06
Media Library /wp-admin/upload.php1,809 ▼135.02 ▲0.02149.17 ▼13.39112.19 ▼10.84

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/live-search-for-post/live-search-for-post.php:31

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === live-search-for-post === )
Please take inspiration from this readme.txt

live-search-for-post/live-search-for-post.php 92% from 13 tests

Analyzing the main PHP file in "Live search for post" version 1.0.0
You should first fix the following items:
  • Text Domain: The text domain should only use lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected137 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP151483
CSS111154

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG files were detected