Pastacode

Use Pastacode to add code into your posts with the awesome PrismJs coloration library. So, past'a code!

v3.0.1Willy BahuaudUpdated Added 400 installs98% rating
33
Score
77
Errors
66
Warnings
+0
Change

Category Scores

Security0
Repo80
Performance100
Maintainability53

Issues to Review

Prioritized issue groups from the latest Plugin Check scan

143 findings

Maintainability

89

12 issue groups

I18n

28

3 issue groups

Security

22

7 issue groups

Repo Compliance

3

3 issue groups

WARNINGMaintainabilityNon-prefixed global variableGlobal variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$about_code".36
Category
Maintainability
Occurrences
36
Severity
warning

Sample message

Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$about_code".

ERRORI18nMissing Translators CommentA function call to __() with texts containing placeholders was found, but was not accompanied by a "translators:" comment on the line above to clarify the meaning of the placeholders.16
Category
I18n
Occurrences
16
Severity
error

Sample message

A function call to __() with texts containing placeholders was found, but was not accompanied by a "translators:" comment on the line above to clarify the meaning of the placeholders.

ERRORMaintainabilityMissing direct file access protectionPHP file should prevent direct access. Add a check like: if ( ! defined( 'ABSPATH' ) ) exit;14
Category
Maintainability
Occurrences
14
Severity
error

Sample message

PHP file should prevent direct access. Add a check like: if ( ! defined( 'ABSPATH' ) ) exit;

WARNINGMaintainabilityNon-prefixed functionFunctions declared in the global namespace by a theme/plugin should start with the theme/plugin prefix. Found: "_pastacode_bitbucket".13
Category
Maintainability
Occurrences
13
Severity
warning

Sample message

Functions declared in the global namespace by a theme/plugin should start with the theme/plugin prefix. Found: "_pastacode_bitbucket".

ERRORI18nMissing Arg DomainMissing $domain parameter in function call to __().11
Category
I18n
Occurrences
11
Severity
error

Sample message

Missing $domain parameter in function call to __().

ERRORSecuritySetting is missing a sanitization callbackSanitization missing for register_setting().10
Category
Security
Occurrences
10
Severity
error

Sample message

Sanitization missing for register_setting().

ERRORSecurityOutput is not escapedAll output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$output'.7
Category
Security
Occurrences
7
Severity
error

Sample message

All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$output'.

ERRORMaintainabilitywp function not compatible with requires wpFunction "do_shortcodes_in_html_tags()" requires WordPress 4.2.3, but your plugin minimum supported version is WordPress 4.0.0.7
Category
Maintainability
Occurrences
7
Severity
error

Sample message

Function "do_shortcodes_in_html_tags()" requires WordPress 4.2.3, but your plugin minimum supported version is WordPress 4.0.0.

WARNINGMaintainabilityMissing VersionResource version not set in call to wp_enqueue_style(). This means new versions of the style may not always be loaded due to browser caching.5
Category
Maintainability
Occurrences
5
Severity
warning

Sample message

Resource version not set in call to wp_enqueue_style(). This means new versions of the style may not always be loaded due to browser caching.

WARNINGMaintainabilityNot In FooterIn footer ($in_footer) is not set explicitly wp_enqueue_script; It is recommended to load scripts in the footer. Please set this value to `true` to load it in the footer, or explicitly `false` if it should be loaded in the header.3
Category
Maintainability
Occurrences
3
Severity
warning

Sample message

In footer ($in_footer) is not set explicitly wp_enqueue_script; It is recommended to load scripts in the footer. Please set this value to `true` to load it in the footer, or explicitly `false` if it should be loaded in the header.

Show 15 more
ERRORMaintainabilitylibrary core files3
Category
Maintainability
Occurrences
3
Severity
error

Sample message

Library files that are already in the WordPress core are not permitted.

WARNINGMaintainabilityDirect Query2
Category
Maintainability
Occurrences
2
Severity
warning

Sample message

Use of a direct database call is discouraged.

WARNINGMaintainabilityNo Caching2
Category
Maintainability
Occurrences
2
Severity
warning

Sample message

Direct database call without caching detected. Consider using wp_cache_get() / wp_cache_set() or wp_cache_delete().

ERRORMaintainabilityblock api version too low2
Category
Maintainability
Occurrences
2
Severity
error

Sample message

Editor blocks must define "apiVersion" 3 or higher in block.json for WordPress 7.0+ iframe editor compatibility.

ERRORMaintainabilitydate date1
Category
Maintainability
Occurrences
1
Severity
error

Sample message

date() is affected by runtime timezone changes which can cause date/time to be incorrectly displayed. Use gmdate() instead.

ERRORSecurityUnsafe printing function1
Category
Security
Occurrences
1
Severity
error

Sample message

All output should be run through an escaping function (like esc_html_e() or esc_attr_e()), found '_e'.

WARNINGSecurityMissing nonce verification1
Category
Security
Occurrences
1
Severity
warning

Sample message

Processing form data without nonce verification.

WARNINGSecuritywp redirect wp redirect1
Category
Security
Occurrences
1
Severity
warning

Sample message

wp_redirect() found. Using wp_safe_redirect(), along with the "allowed_redirect_hosts" filter if needed, can help avoid any chances of malicious redirects within code. It is also important to remember to call exit() after a redirect so that no other unwanted code is executed.

WARNINGSecurityInput is not sanitized1
Category
Security
Occurrences
1
Severity
warning

Sample message

Detected usage of a non-sanitized input variable: $_GET['_wpnonce']

WARNINGSecurityRequest data is not unslashed1
Category
Security
Occurrences
1
Severity
warning

Sample message

$_GET['_wpnonce'] not unslashed before sanitization. Use wp_unslash() or similar

ERRORMaintainabilityDeprecated function: screen_icon1
Category
Maintainability
Occurrences
1
Severity
error

Sample message

screen_icon() has been deprecated since WordPress version 3.8.0.

ERRORI18nText Domain Mismatch1
Category
I18n
Occurrences
1
Severity
error

Sample message

Mismatched text domain. Expected 'pastacode' but got 'pastebin'.

ERRORRepo Complianceoutdated tested upto header1
Category
Repo Compliance
Occurrences
1
Severity
error

Sample message

Tested up to: 6.9 < 7.0. The "Tested up to" value in your plugin is not set to the current version of WordPress. This means your plugin will not show up in searches, as we require plugins to be compatible and documented as tested up to the most recent version of WordPress.

ERRORRepo Complianceplugin header no license1
Category
Repo Compliance
Occurrences
1
Severity
error

Sample message

Missing "License" in Plugin Header. Please update your Plugin Header with a valid GPLv2 (or later) compatible license.

ERRORRepo Compliancereadme mismatched header requires1
Category
Repo Compliance
Occurrences
1
Severity
error

Sample message

Mismatched Requires at least: 3.1 != 4.0. "Requires at least" needs to be exactly the same with that in your main plugin file's header.

External Connections

Potential connections found in static code analysis.

42 domains

Outbound calls

297

External assets

0

Incoming endpoints

3

Notable Domains

codemirror.net186 · outbound
dev.mysql.com12 · outbound
gitlab.com4 · outbound
msdn.microsoft.com4 · outbound
pastebin.com3 · outbound
api.github.com2 · outbound

Platform / Reference Domains

github.com42 · platform/reference
w3.org2 · platform/reference
opensource.org1 · platform/reference

External Asset Domains

No external asset domains detected.

Incoming Endpoints

/wp-json/pastacode/v2/retrieve_codeREST

register_rest_route

wp_ajax_nopriv_pastacode-get-source-codepublic

wp_ajax

Admin AJAX endpoints1
wp_ajax_pastacode-get-source-codeauthenticated

wp_ajax

Score History

First score snapshot

v3.0.1

33

Latest

Findings
143
Errors
77
Warnings
66
Check
2.0.0

Relationship Map

Author, categories, issues, domains, and nearby plugins.

37 nodes

Related Plugins