78% pics-mash

Code Review | Pics Mash

WordPress plugin Pics Mash scored78%from 54 tests.

About plugin

  • Plugin page: pics-mash
  • Plugin version: 1.8
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.5
  • WordPress version: 6.3.1
  • First release: Nov 11, 2012
  • Latest release: Jul 8, 2013
  • Number of updates: 24
  • Update frequency: every 10.0 days
  • Top authors: mikemayhem3030 (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

20+ active /12,059 total downloads

Benchmarks

Plugin footprint 82% 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.15MB] [CPU: ▼8.89ms] 75% from 4 tests

This is a short check of server-side resources used by Pics Mash
Please take the time to fix the following items
  • CPU: You should keep total CPU usage under 500.00ms (currently 3,459.60ms on /wp-admin/admin.php?page=picsmash-plugin-config)
PageMemory (MB)CPU Time (ms)
Home /3.66 ▲0.1943.10 ▲3.39
Dashboard /wp-admin3.50 ▲0.1548.79 ▼13.58
Posts /wp-admin/edit.php3.43 ▲0.0732.78 ▼20.68
Add New Post /wp-admin/post-new.php6.10 ▲0.2187.56 ▼2.95
Media Library /wp-admin/upload.php3.42 ▲0.1937.60 ▲1.64
My Pics Mash /wp-admin/admin.php?page=picsmash-plugin-config4.513,459.60
Share /wp-admin/admin.php?page=picsmash-plugin-share3.3831.11
Settings /wp-admin/admin.php?page=picsmash-plugin-settings3.3830.92

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 22 new files
Database: no new tables, 8 new options
New WordPress options
Kfactor
widget_recent-comments
freepicsmashshared
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Pics Mash
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,989 ▲24314.13 ▼0.436.20 ▲4.3446.39 ▲6.98
Dashboard /wp-admin2,246 ▲914.90 ▼0.81106.41 ▲0.5469.88 ▲29.43
Posts /wp-admin/edit.php2,155 ▲662.32 ▲0.3241.79 ▲0.8332.41 ▼4.56
Add New Post /wp-admin/post-new.php1,702 ▲16022.61 ▲4.13712.95 ▲111.7329.11 ▼19.02
Media Library /wp-admin/upload.php1,450 ▲624.32 ▲0.06107.94 ▲11.9771.98 ▲31.16
My Pics Mash /wp-admin/admin.php?page=picsmash-plugin-config1,3004.51128.6949.39
Share /wp-admin/admin.php?page=picsmash-plugin-share1,0644.49119.9628.78
Settings /wp-admin/admin.php?page=picsmash-plugin-settings1,2124.8695.5340.90

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 8 options
    • freepicsmashshared
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • Kfactor
    • widget_recent-comments
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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
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 register_activation_hook() in wp-content/plugins/pics-mash/PicsMash.php:14

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There are user-side issues you should fix
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=picsmash-plugin-settings
    • > Network (severe)
    wp-content/plugins/pics-mash/i/ae-bg-400t.png - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=picsmash-plugin-settings
    • > Network (severe)
    http://picsmashplugin.com/23.png - Failed to load resource: net::ERR_NAME_NOT_RESOLVED
    • > GET request to /wp-admin/admin.php?page=picsmash-plugin-settings
    • > Network (severe)
    http://picsmashplugin.com/24.png - Failed to load resource: net::ERR_NAME_NOT_RESOLVED
    • > GET request to /wp-admin/admin.php?page=picsmash-plugin-settings
    • > Network (severe)
    http://picsmashplugin.com/25.png - Failed to load resource: net::ERR_NAME_NOT_RESOLVED
    • > GET request to /wp-admin/admin.php?page=picsmash-plugin-settings
    • > Network (severe)
    http://picsmashplugin.com/22.png - Failed to load resource: net::ERR_NAME_NOT_RESOLVED

Optimizations

Plugin configuration 93% 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 need to be fixed:
  • Tags: Please reduce the number of tags, currently 16 tag instead of maximum 10
The official readme.txt might help

pics-mash/PicsMash.php 92% from 13 tests

Analyzing the main PHP file in "Pics Mash" version 1.8
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("pics-mash.php" instead of "PicsMash.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected1,056 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP137775921
CSS21918103
JavaScript221032

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.13
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%
Functions42
▷ Named functions42100.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
14 PNG files occupy 0.09MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
i/tweet.png3.74KB2.39KB▼ 36.25%
i/image.png0.90KB1.01KB0.00%
i/CCbuy.png3.14KB2.66KB▼ 15.04%
i/movie.png0.42KB0.46KB0.00%
i/CCion.png8.16KB4.22KB▼ 48.25%