83% dxfview

Code Review | DXFViewer

WordPress plugin DXFViewer scored83%from 54 tests.

About plugin

  • Plugin page: dxfview
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Oct 20, 2016
  • Latest release: Oct 20, 2016
  • Number of updates: 7
  • Update frequency: every 6.7 days
  • Top authors: aviket (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,426 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼7.79ms] Passed 4 tests

A check of server-side resources used by DXFViewer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.18 ▼4.05
Dashboard /wp-admin3.32 ▲0.0252.04 ▼1.17
Posts /wp-admin/edit.php3.37 ▲0.0149.61 ▼1.78
Add New Post /wp-admin/post-new.php5.90 ▲0.0184.97 ▼24.16
Media Library /wp-admin/upload.php3.24 ▲0.0137.50 ▲0.67
DXFView Options /wp-admin/options-general.php?page=DXFView_options3.2133.30

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 17 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
DXFView-Settings
widget_theysaidso_widget
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for DXFViewer
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲3214.25 ▼0.101.84 ▲0.1145.65 ▲4.64
Dashboard /wp-admin2,199 ▲225.59 ▼0.0485.65 ▼8.9637.75 ▼3.35
Posts /wp-admin/edit.php2,107 ▲71.99 ▼0.0235.95 ▼6.7934.24 ▼8.48
Add New Post /wp-admin/post-new.php1,529 ▼623.14 ▲5.00626.85 ▼3.7752.89 ▼15.49
Media Library /wp-admin/upload.php1,398 ▼24.15 ▼0.0099.25 ▼3.4744.27 ▼2.16
DXFView Options /wp-admin/options-general.php?page=DXFView_options8632.1524.6527.15

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not 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
Please take a closer look at the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function trailingslashit() in wp-content/plugins/dxfview/DXFView.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes:
  • Tested up to: Invalid version format
  • Requires at least: Invalid version format
The official readme.txt is a good inspiration

dxfview/DXFView.php 92% from 13 tests

The entry point to "DXFViewer" version 1.0 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("dxfview.php" instead of "DXFView.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
There were no executable files found in this plugin7,197 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript91,0521,1006,959
PHP5698238

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.13
Average class complexity4.33
▷ Minimum class complexity1.00
▷ Maximum class complexity6.00
Average method complexity1.53
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods19
▷ Static methods00.00%
▷ Public methods19100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin