84% mobile-friendly-twenty-ten

Code Review | Mobile Friendly Twenty Ten

WordPress plugin Mobile Friendly Twenty Ten scored84%from 54 tests.

About plugin

  • Plugin page: mobile-friendly-t...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.8
  • WordPress version: 6.3.1
  • First release: Sep 10, 2015
  • Latest release: Jul 15, 2022
  • Number of updates: 9
  • Update frequency: every 278.1 days
  • Top authors: shaked69 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /3,422 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.00MB] [CPU: ▼7.62ms] Passed 4 tests

This is a short check of server-side resources used by Mobile Friendly Twenty Ten
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.69 ▼7.88
Dashboard /wp-admin3.31 ▲0.0048.37 ▼3.94
Posts /wp-admin/edit.php3.36 ▲0.0047.76 ▼0.61
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.93 ▼18.05
Media Library /wp-admin/upload.php3.24 ▲0.0036.49 ▲4.66

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Mobile Friendly Twenty Ten
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,791 ▲3014.34 ▼0.242.31 ▲0.7255.59 ▲16.77
Dashboard /wp-admin2,198 ▲215.57 ▲0.0381.46 ▼14.1744.09 ▼0.40
Posts /wp-admin/edit.php2,103 ▲31.98 ▼0.0544.45 ▲7.0335.89 ▼0.16
Add New Post /wp-admin/post-new.php1,526 ▼223.63 ▲0.59646.53 ▼48.0658.47 ▲15.76
Media Library /wp-admin/upload.php1,400 ▼34.19 ▼0.0995.85 ▼6.6243.69 ▼1.83

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/mobile-friendly-twenty-ten/mobile-friendly-twenty-ten.php:14

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

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare 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 ( === mobile-friendly-twenty-ten === )
The official readme.txt might help

mobile-friendly-twenty-ten/mobile-friendly-twenty-ten.php Passed 13 tests

The main PHP file in "Mobile Friendly Twenty Ten" ver. 1.2 adds more information about the plugin and also serves as the entry point for this plugin
78 characters long description:
This plugin adapts Twenty Ten theme to mobile while keeping its general looks.

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 detected72 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
CSS117866
PHP14126

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Functions1
▷ Named functions1100.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