84% lti-sitemap

Code Review | LTI Sitemap

WordPress plugin LTI Sitemap scored84%from 54 tests.

About plugin

  • Plugin page: lti-sitemap
  • Plugin version: 0.5.1
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jun 4, 2015
  • Latest release: Dec 12, 2015
  • Number of updates: 10
  • Update frequency: every 19.2 days
  • Top authors: lti (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,481 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.23MB] [CPU: ▼0.98ms] Passed 4 tests

Server-side resources used by LTI Sitemap
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.69 ▲0.2340.74 ▼2.33
Dashboard /wp-admin3.53 ▲0.2250.09 ▼0.21
Posts /wp-admin/edit.php3.64 ▲0.2949.34 ▼3.85
Add New Post /wp-admin/post-new.php6.13 ▲0.2496.99 ▲3.19
Media Library /wp-admin/upload.php3.45 ▲0.2238.80 ▲2.46

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 175 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
lti_sitemap_options
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

LTI Sitemap: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,824 ▲5313.64 ▼1.011.78 ▼0.1738.11 ▼9.43
Dashboard /wp-admin2,224 ▲365.84 ▲0.93121.76 ▲17.2139.35 ▼3.15
Posts /wp-admin/edit.php2,116 ▲302.06 ▲0.0156.23 ▲16.5031.74 ▼5.84
Add New Post /wp-admin/post-new.php1,531 ▲1017.66 ▼5.47674.06 ▲0.2557.90 ▲1.66
Media Library /wp-admin/upload.php1,409 ▲244.23 ▲0.01125.36 ▲19.2243.84 ▼2.70

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
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded

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
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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
Please fix the following
  • 49× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Locale' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Locale.php:21
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\Intl\\Data\\Bundle\\Reader\\BundleReaderInterface' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Data/Bundle/Reader/IntlBundleReader.php:24
    • > PHP Fatal error
      require_once(): Failed opening required 'wp-content/plugins/lti-sitemap/vendor/lti/google/src/Google/../autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/lti-sitemap/vendor/lti/google/src/Google/Collection.php on line 4
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Intl\\Data\\Generator\\AbstractDataGenerator' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Data/Generator/ScriptDataGenerator.php:25
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\Intl\\Data\\Bundle\\Reader\\BundleEntryReaderInterface' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Data/Bundle/Reader/BundleEntryReader.php:29
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Intl\umberFormatter\umberFormatter' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Resources/stubs/NumberFormatter.php:21
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\Intl\\Exception\\ExceptionInterface' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Exception/RuntimeException.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Google_Service_Webmasters' not found in wp-content/plugins/lti-sitemap/vendor/lti/google/src/Lti/webmaster.php:139
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/lti-sitemap/src/admin/partials/postbox.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Intl\\Data\\Generator\\AbstractDataGenerator' not found in wp-content/plugins/lti-sitemap/vendor/symfony/intl/Data/Generator/CurrencyDataGenerator.php:26

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need to be fixed:
  • Tags: There are too many tags (17 tag instead of maximum 10)
  • Requires at least: Version not formatted correctly
The official readme.txt might help

lti-sitemap/lti-sitemap.php Passed 13 tests

The principal PHP file in "LTI Sitemap" v. 0.5.1 is loaded by WordPress automatically on each request
85 characters long description:
Hassle free XML Sitemaps: pick your featured content, let search engines do the rest!

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin12,904 lines of code in 159 files:
LanguageFilesBlank linesComment linesLines of code
PHP1522,3636,83411,295
JSON3001,302
XSLT2380305
CSS1001
JavaScript1001

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity6.64
▷ Minimum class complexity1.00
▷ Maximum class complexity60.00
Average method complexity2.16
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces20
Interfaces13
Traits0
Classes171
▷ Abstract classes127.02%
▷ Concrete classes15992.98%
▷ Final classes21.26%
Methods935
▷ Static methods778.24%
▷ Public methods80686.20%
▷ Protected methods565.99%
▷ Private methods737.81%
Functions22
▷ Named functions1777.27%
▷ Anonymous functions522.73%
Constants122
▷ Global constants54.10%
▷ Class constants11795.90%
▷ Public constants117100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin