62% tina-mvc

Code Review | Author: Francis Crossen (fcrossen)

WordPress plugin Author: Francis Crossen (fcrossen) scored62%from 54 tests.

About plugin

  • Plugin page: tina-mvc
  • Plugin version: 1.0.13
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.5.1
  • WordPress version: 6.3.1
  • First release: Feb 28, 2010
  • Latest release: Nov 22, 2013
  • Number of updates: 324
  • Update frequency: every 4.2 days
  • Top authors: fcrossen (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /8,167 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼1.38MB] [CPU: ▼45.36ms] Passed 4 tests

An overview of server-side resources used by Author: Francis Crossen (fcrossen)
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.56 ▼0.9010.66 ▼29.78
Dashboard /wp-admin2.66 ▼0.6914.23 ▼44.45
Posts /wp-admin/edit.php2.66 ▼0.7013.62 ▼33.21
Add New Post /wp-admin/post-new.php2.66 ▼3.2313.99 ▼73.98
Media Library /wp-admin/upload.php2.66 ▼0.5711.83 ▼19.66
Widgets, Shortcodes, call_controller() /wp-admin/admin.php?page=tina_mvc_widgets_shortcodes2.6512.83
Using Views /wp-admin/admin.php?page=tina_mvc_using_views2.6515.20
Table and Pagination Helpers /wp-admin/admin.php?page=tina_mvc_table_and_pagination_helpers2.6512.17
Tina MVC /wp-admin/admin.php?page=tina_mvc_for_wordpress2.6515.20
Form Helper - Advanced Use /wp-admin/admin.php?page=tina_mvc_form_helper_advanced2.6512.64
Helper Functions /wp-admin/admin.php?page=tina_mvc_helper_functions2.6514.51
File Locations /wp-admin/admin.php?page=tina_mvc_file_locations2.6512.07
Form Helper - Introduction /wp-admin/admin.php?page=tina_mvc_form_helper_intro2.6513.84
Hello World Tutorial /wp-admin/admin.php?page=tina_mvc_hello_world2.6513.30
Custom login functionality /wp-admin/admin.php?page=tina_mvc_custom_login2.6513.56

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 109 new files
Database: no new tables, 9 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_tina_mvc_widget
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts
tina_mvc_settings
tina_mvc_plugin_active

Browser metrics Passed 4 tests

An overview of browser requirements for Author: Francis Crossen (fcrossen)
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,701 ▼4514.79 ▲0.231.20 ▼0.7043.04 ▲0.26
Dashboard /wp-admin2,284 ▲964.86 ▼1.02104.31 ▼0.2943.15 ▲3.16
Posts /wp-admin/edit.php2,164 ▲752.02 ▲0.0136.10 ▼7.1632.88 ▼4.38
Add New Post /wp-admin/post-new.php1,591 ▲7423.20 ▲5.61665.64 ▼17.6065.46 ▲10.60
Media Library /wp-admin/upload.php1,466 ▲814.23 ▲0.0396.47 ▼0.6344.16 ▲2.43
Widgets, Shortcodes, call_controller() /wp-admin/admin.php?page=tina_mvc_widgets_shortcodes1,0122.0226.2154.22
Using Views /wp-admin/admin.php?page=tina_mvc_using_views1,6272.2922.3533.02
Table and Pagination Helpers /wp-admin/admin.php?page=tina_mvc_table_and_pagination_helpers4,4222.0324.8849.91
Tina MVC /wp-admin/admin.php?page=tina_mvc_for_wordpress1,0552.0222.0436.61
Form Helper - Advanced Use /wp-admin/admin.php?page=tina_mvc_form_helper_advanced1,9772.0221.9633.08
Helper Functions /wp-admin/admin.php?page=tina_mvc_helper_functions1,7342.0223.6634.35
File Locations /wp-admin/admin.php?page=tina_mvc_file_locations1,0862.0221.7934.81
Form Helper - Introduction /wp-admin/admin.php?page=tina_mvc_form_helper_intro2,2102.0222.7136.43
Hello World Tutorial /wp-admin/admin.php?page=tina_mvc_hello_world1,7802.1423.1934.03
Custom login functionality /wp-admin/admin.php?page=tina_mvc_custom_login9412.0223.7828.35

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall without warnings or errors
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in tina_mvc_widget is deprecated since version 4.3.0! Use __construct() instead.
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_tina_mvc_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 10 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=tina_mvc_custom_login
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in tina_mvc_widget is deprecated since version 4.3.0! Use __construct() instead.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=tina_mvc_custom_login
    • > Notice in wp-content/plugins/tina-mvc/tina_mvc/admin_pages/admin_pages_controller.php+94
    Undefined property: admin_pages_controller::$view_data

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 5× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/tina-mvc/tina_mvc/pages/registration_reset_password_email.php
    • > /wp-content/plugins/tina-mvc/tina_mvc/pages/registration_index_email.php
    • > /wp-content/plugins/tina-mvc/tina_mvc/pages/registration_password_reset_confirmation_email.php
    • > /wp-content/plugins/tina-mvc/tina_mvc/3rd_party/recaptcha/example-mailhide.php
    • > /wp-content/plugins/tina-mvc/tina_mvc/3rd_party/recaptcha/example-captcha.php
  • 21× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/tina_mvc/pages/registration_controller.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/tina_mvc/pages/tina_mvc_child_page_controller.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/samples/02_using_views/using_views_2_controller.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/tina_mvc/pages/index_controller.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/samples/12_table_and_pagination_helpers/page_test_3_controller.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/tina_mvc/admin_pages/admin_pages_controller.php:13
    • > PHP Warning
      Creating default object from empty value in wp-content/plugins/tina-mvc/user_apps/default/app_settings_sample.php on line 20
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/samples/01_hello_world_tutorial/hello_world_controller.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/samples/12_table_and_pagination_helpers/html_table_controller.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'TINA_MVC\\tina_mvc_controller_class' not found in wp-content/plugins/tina-mvc/samples/01_hello_world_tutorial/index_controller.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === Author: Francis Crossen (fcrossen) === )
The official readme.txt might help

tina-mvc/tina_mvc.php 92% from 13 tests

"Author: Francis Crossen (fcrossen)" version 1.0.13's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("tina-mvc.php" instead of "tina_mvc.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected4,920 lines of code in 66 files:
LanguageFilesBlank linesComment linesLines of code
PHP642,2574,1704,900
CSS241520

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity9.38
▷ Minimum class complexity1.00
▷ Maximum class complexity65.00
Average method complexity3.08
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes60
▷ Abstract classes00.00%
▷ Concrete classes60100.00%
▷ Final classes00.00%
Methods242
▷ Static methods10.41%
▷ Public methods22191.32%
▷ Protected methods00.00%
▷ Private methods218.68%
Functions48
▷ Named functions48100.00%
▷ Anonymous functions00.00%
Constants12
▷ Global constants12100.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
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
tina_mvc/admin_pages/assets/tina_mvc_widget.png16.85KB7.46KB▼ 55.75%