79% repurpost

Code Review | Plugin Repurpost

WordPress plugin Plugin Repurpost scored79%from 54 tests.

About plugin

  • Plugin page: repurpost
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.0
  • WordPress version: 6.3.1
  • First release: May 5, 2021
  • Latest release: May 20, 2022
  • Number of updates: 13
  • Update frequency: every 29.2 days
  • Top authors: repurpost (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /377 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
Installer ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▲1.41ms] Passed 4 tests

Server-side resources used by Plugin Repurpost
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0540.03 ▼1.75
Dashboard /wp-admin3.36 ▲0.0552.27 ▲4.11
Posts /wp-admin/edit.php3.47 ▲0.1154.48 ▲3.87
Add New Post /wp-admin/post-new.php6.22 ▲0.3299.22 ▲12.24
Media Library /wp-admin/upload.php3.28 ▲0.0536.59 ▼0.61

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 38 new files
Database: no new tables, 9 new options
New WordPress options
db_upgraded
theysaidso_admin_options
repurpostWP_blogusers
can_compress_scripts
repurpostWP_token
widget_recent-posts
repurpostWP_referrer_status
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Plugin Repurpost
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,811 ▲2514.57 ▲0.281.78 ▼0.3040.74 ▼4.47
Dashboard /wp-admin2,215 ▲355.64 ▲0.0390.35 ▲1.4341.27 ▲0.14
Posts /wp-admin/edit.php2,123 ▲232.00 ▲0.0038.89 ▲1.8237.40 ▼1.74
Add New Post /wp-admin/post-new.php1,543 ▲1723.26 ▼0.20665.15 ▼71.8967.05 ▼7.20
Media Library /wp-admin/upload.php1,423 ▲204.29 ▲0.0495.94 ▼11.2943.45 ▼3.07

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 9 options in the database
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • repurpostWP_token
    • repurpostWP_referrer_status
    • widget_recent-posts
    • repurpostWP_blogusers
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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
The following issues need your attention
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/repurpost/public/partials/repurpost-public-display.php
    • > /wp-content/plugins/repurpost/repurpost.php
  • 5× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/repurpost/admin/partials/repurpost-admin-display.php:41
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/repurpost/admin/partials/alerts/repurpost-admin-alert-yoast.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/repurpost/api/rest_api/routes.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/repurpost/admin/partials/repurpost-admin-page.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/repurpost/admin/partials/alerts/repurpost-admin-alert-polylang.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: content marketing, repurpost, content streams

repurpost/repurpost.php Passed 13 tests

"Plugin Repurpost" version 1.1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
81 characters long description:
This plugin enables the integration between the Repurpost Platform and Wordpress.

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
Everything looks great! No dangerous files found in this plugin1,871 lines of code in 31 files:
LanguageFilesBlank linesComment linesLines of code
PHP266286311,866
JavaScript22334
Markdown1001
CSS2080

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity2.75
▷ Minimum class complexity1.00
▷ Maximum class complexity8.00
Average method complexity1.58
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods24
▷ Static methods28.33%
▷ Public methods1979.17%
▷ Protected methods00.00%
▷ Private methods520.83%
Functions114
▷ Named functions5750.00%
▷ Anonymous functions5750.00%
Constants1
▷ Global constants1100.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
No PNG images were found in this plugin