62% an-easy-skype-button

Code Review | An Easy Skype Button

WordPress plugin An Easy Skype Button scored62%from 54 tests.

About plugin

  • Plugin page: an-easy-skype-button
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.3
  • WordPress version: 6.3.1
  • First release: Nov 4, 2015
  • Latest release: Nov 5, 2015
  • Number of updates: 7
  • Update frequency: every 0.1 days
  • Top authors: iaaxpage (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,647 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.02MB] [CPU: ▼1.55ms] Passed 4 tests

This is a short check of server-side resources used by An Easy Skype Button
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.76 ▼1.96
Dashboard /wp-admin3.33 ▲0.0349.24 ▼3.07
Posts /wp-admin/edit.php3.38 ▲0.0250.15 ▲0.90
Add New Post /wp-admin/post-new.php5.91 ▲0.0293.97 ▲1.79
Media Library /wp-admin/upload.php3.25 ▲0.0236.04 ▼2.06
Skype Settings /wp-admin/options-general.php?page=octopus-skype-button3.4036.38

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 405 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for An Easy Skype Button
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲5914.28 ▼0.071.80 ▲0.0339.56 ▼3.52
Dashboard /wp-admin2,202 ▲255.62 ▼0.0181.92 ▼3.4337.50 ▼7.92
Posts /wp-admin/edit.php2,104 ▲42.03 ▲0.0442.21 ▲7.3135.99 ▼1.40
Add New Post /wp-admin/post-new.php1,531 ▲523.16 ▼0.50675.82 ▲49.5949.18 ▲2.78
Media Library /wp-admin/upload.php1,401 ▼24.26 ▲0.02108.48 ▲6.1346.52 ▲2.66
Skype Settings /wp-admin/options-general.php?page=octopus-skype-button7872.1422.8823.66

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=octopus-skype-button
    • > Notice in wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/src/Mustache/Parser.php+278
    Trying to access array offset on value of type null

SRP 0% 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
  • 2× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/bin/build_bootstrap.php
    • > /wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/bin/build_bootstrap.php
  • 118× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/test/Mustache/Test/TokenizerTest.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/test/Mustache/Test/Exception/UnknownFilterExceptionTest.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/test/Mustache/Test/FiveThree/Functional/StrictCallablesTest.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'Mustache_Test_FunctionalTestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/test/Mustache/Test/Cache/FilesystemCacheTest.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/test/Mustache/Test/AutoloaderTest.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'Mustache_Loader' not found in wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/src/Mustache/Loader/InlineLoader.php:50
    • > PHP Fatal error
      Uncaught Error: Interface 'Mustache_Loader' not found in wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/src/Mustache/Loader/StringLoader.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/test/Mustache/Test/Exception/SyntaxExceptionTest.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/test/Mustache/Test/Loader/StringLoaderTest.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/test/Mustache/Test/Functional/CallTest.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: mustache, wpexpress, skype button

an-easy-skype-button/init.php 92% from 13 tests

The primary PHP file in "An Easy Skype Button" version 0.1 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("an-easy-skype-button.php" instead of "init.php")

Code Analysis 5% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Please fix the following items
  • You should never include executable (binary) or otherwise dangerous files in your plugin
    • .ms - Maxwell Script in Maxwell Render
      • wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/test/fixtures/templates/alpha.ms
      • wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/test/fixtures/templates/alpha.ms
      • wp-content/plugins/an-easy-skype-button/vendor/page-carbajal/wpexpress/vendor/mustache/mustache/test/fixtures/templates/beta.ms
      • wp-content/plugins/an-easy-skype-button/vendor/mustache/mustache/test/fixtures/templates/beta.ms
9,463 lines of code in 195 files:
LanguageFilesBlank linesComment linesLines of code
PHP1431,9684,2618,798
Markdown4960207
JSON510195
Mustache3630163
PO File28848
YAML26026
XML12015
CSS11011
JavaScript1030

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity3.91
▷ Minimum class complexity1.00
▷ Maximum class complexity51.00
Average method complexity1.78
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces10
Interfaces11
Traits0
Classes242
▷ Abstract classes124.96%
▷ Concrete classes23095.04%
▷ Final classes00.00%
Methods983
▷ Static methods717.22%
▷ Public methods83584.94%
▷ Protected methods434.37%
▷ Private methods10510.68%
Functions70
▷ Named functions57.14%
▷ Anonymous functions6592.86%
Constants128
▷ Global constants00.00%
▷ Class constants128100.00%
▷ Public constants128100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.13MB with 0.10MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
resources/images/shortcode-demo.png100.88KB31.86KB▼ 68.42%
resources/images/demo-button.png10.43KB2.19KB▼ 78.96%
resources/images/configure-account.png24.60KB5.87KB▼ 76.13%