74% wp-monalisa

Code Review | wp-Monalisa

WordPress plugin wp-Monalisa scored74%from 54 tests.

About plugin

  • Plugin page: wp-monalisa
  • Plugin version: 6.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: May 20, 2009
  • Latest release: Sep 27, 2022
  • Number of updates: 150
  • Update frequency: every 34.6 days
  • Top authors: tuxlog (100%)

Code review

54 tests

User reviews

24 reviews

Install metrics

1,000+ active /94,209 total downloads

Benchmarks

Plugin footprint 65% from 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.36MB] [CPU: ▼2.94ms] Passed 4 tests

Server-side resources used by wp-Monalisa
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.82 ▲0.3641.34 ▲6.08
Dashboard /wp-admin3.66 ▲0.3546.71 ▼4.19
Posts /wp-admin/edit.php3.78 ▲0.4247.88 ▲0.18
Add New Post /wp-admin/post-new.php6.25 ▲0.3694.76 ▼8.91
Media Library /wp-admin/upload.php3.59 ▲0.3537.44 ▲1.18

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 80 new files
Database: 1 new table, 8 new options
New tables
wp_monalisa
New WordPress options
theysaidso_admin_options
wpml_use_smilies_backup
db_upgraded
wpml-opts
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for wp-Monalisa
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,906 ▲17113.61 ▼1.004.69 ▲2.9639.44 ▲0.59
Dashboard /wp-admin2,230 ▲394.91 ▼1.00111.11 ▲3.8691.73 ▲48.75
Posts /wp-admin/edit.php2,125 ▲362.03 ▲0.0334.45 ▼6.7334.36 ▲0.30
Add New Post /wp-admin/post-new.php1,551 ▲3718.06 ▲0.45593.34 ▼26.6634.85 ▼24.64
Media Library /wp-admin/upload.php1,417 ▲294.22 ▲0.0196.32 ▼1.9866.34 ▲26.97

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Zombie tables detected upon uninstall: 1 table
    • wp_monalisa
  • This plugin does not fully uninstall, leaving 8 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • wpml-opts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • wpml_use_smilies_backup
    • widget_theysaidso_widget

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 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wp-monalisa/wpml-autoupdate.php:117
    • > PHP Fatal error
      Uncaught Error: Call to undefined function sanitize_file_name() in wp-content/plugins/wp-monalisa/wpml-comment.php:24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wp-monalisa/wpml-autoupdate.php:117

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === wp-monalisa === )
The official readme.txt might help

wp-monalisa/wp-monalisa.php Passed 13 tests

This is the main PHP file of "wp-Monalisa" version 6.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
126 characters long description:
wp-Monalisa is the plugin that smiles at you like monalisa does. place the smilies of your choice in posts, pages or comments.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin4,374 lines of code in 28 files:
LanguageFilesBlank linesComment linesLines of code
PO File109541,1902,121
PHP113517161,672
JavaScript570123415
CSS12217151
make12315

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.35
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%
Functions43
▷ Named functions43100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
4 compressed PNG files occupy 0.00MB
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
down.png1.47KB1.41KB▼ 4.38%
smiley.png0.83KB0.78KB▼ 6.34%
up.png1.48KB1.40KB▼ 4.90%
yes.png0.66KB0.53KB▼ 19.79%