10% stfcopyright

Code Review | stfCopyright

WordPress plugin stfCopyright scored10%from 54 tests.

About plugin

  • Plugin page: stfcopyright
  • Plugin version: 1.1
  • PHP compatiblity: 5.6.30+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.2.1
  • WordPress version: 6.3.1
  • First release: Nov 27, 2017
  • Latest release: Jul 14, 2019
  • Number of updates: 9
  • Update frequency: every 66.1 days
  • Top authors: funfunkan (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /900 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
These installer errors require your attention
  • Install procedure had errors
    • > Notice in wp-content/plugins/stfcopyright/stfCopyright.php+25
    date_default_timezone_set(): Timezone ID '' is invalid

Server metrics [RAM: ▼4.70MB] [CPU: ▼534,395.94ms] Passed 4 tests

Analyzing server-side resources used by stfCopyright
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.12 ▼1.386.10 ▼48.70
Dashboard /wp-admin2.14 ▼12.386.67 ▼2,137,393.35
Posts /wp-admin/edit.php2.14 ▼1.257.29 ▼48.30
Add New Post /wp-admin/post-new.php2.14 ▼3.786.12 ▼93.42
Media Library /wp-admin/upload.php2.14 ▼1.136.69 ▼32.61
stfCopyright /wp-admin/options-general.php?page=stfcp2.157.61

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 8 new files
Database: no new tables, 13 new options
New WordPress options
widget_theysaidso_widget
stf_tools_type
stf_tools_freetext
theysaidso_admin_options
stf_tools
stf_tools_owner
stf_tools_iyear
stf_tools_uyear
widget_recent-posts
db_upgraded
...

Browser metrics Passed 4 tests

stfCopyright: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.34 ▼0.391.62 ▼0.1142.24 ▼2.21
Dashboard /wp-admin2,202 ▲285.59 ▼0.0682.65 ▼16.9443.68 ▲1.32
Posts /wp-admin/edit.php2,104 ▲12.00 ▼0.0239.08 ▲2.9839.11 ▲4.63
Add New Post /wp-admin/post-new.php1,532 ▲622.86 ▼0.92672.30 ▼21.4653.35 ▼0.75
Media Library /wp-admin/upload.php1,404 ▲44.15 ▲0.0597.29 ▼17.7947.59 ▼1.91
stfCopyright /wp-admin/options-general.php?page=stfcp1,0011.6928.8435.08

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/stfcopyright/stfCopyright.php+25
    date_default_timezone_set(): Timezone ID '' is invalid
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=stfcp
    • > Notice in wp-content/plugins/stfcopyright/stfCopyright.php+25
    date_default_timezone_set(): Timezone ID '' is invalid
  • 13 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=stfcp
    • > POST request to /wp-cron.php?doing_wp_cron=1697551793.8827230930328369140625
    • > Warning in wp-content/plugins/easy-age-verifier/lib/extras/wpApi.php+48
    file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known
  • 13 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=stfcp
    • > POST request to /wp-cron.php?doing_wp_cron=1697551793.8827230930328369140625
    • > Warning in wp-content/plugins/easy-age-verifier/lib/extras/wpApi.php+48
    file_get_contents(http://www.fillyourtaproom.com/wp-json/wp/v2/posts?per_page=10): failed to open stream: php_network_getaddresses: getaddrinfo failed: Name or service not known

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 take a closer look at 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 load_plugin_textdomain() in wp-content/plugins/stfcopyright/stfCopyright.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: tag, copyright, copyright generator, footer

stfcopyright/stfCopyright.php 85% from 13 tests

"stfCopyright" version 1.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
  • Text Domain: The text domain should only use lowercase characters and dashes
  • Main file name: Name the main plugin file the same as the plugin slug ("stfcopyright.php" instead of "stfCopyright.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected430 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP12362249
PO File35454181

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity2.40
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin