-
-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pods 3.2.8 #7347
base: main
Are you sure you want to change the base?
Pods 3.2.8 #7347
Conversation
PR Summary
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
Public method name "Base::should_autop" is not in camel caps format
pods/src/Pods/Blocks/Types/Base.php
Line 284 in 8b99c43
public function should_autop( $content, array $attributes = [] ): bool { |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionDeclaration.BraceOnSameLine
Opening brace should be on a new line
pods/src/Pods/Blocks/Types/Base.php
Line 284 in 8b99c43
public function should_autop( $content, array $attributes = [] ): bool { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 285 in 8b99c43
$should_autop = ( |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 286 in 8b99c43
is_string( $content ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 287 in 8b99c43
&& false === strpos( $content, '<div' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 288 in 8b99c43
&& false === strpos( $content, '<ul' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 289 in 8b99c43
&& false === strpos( $content, '<ol' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 290 in 8b99c43
&& false === strpos( $content, '<h' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 291 in 8b99c43
&& false === strpos( $content, '<p' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 292 in 8b99c43
); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 294 in 8b99c43
/** |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 295 in 8b99c43
* Allow filtering whether to apply wpautop to the block content output. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 296 in 8b99c43
* |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 297 in 8b99c43
* This is used for things like Field block render or List block render of the no items found message. |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 110 characters
pods/src/Pods/Blocks/Types/Base.php
Line 297 in 8b99c43
* This is used for things like Field block render or List block render of the no items found message. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 298 in 8b99c43
* |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 299 in 8b99c43
* @since TBD |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 300 in 8b99c43
* |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 301 in 8b99c43
* @param bool $should_autop Whether to apply wpautop to the block content output. |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 98 characters
pods/src/Pods/Blocks/Types/Base.php
Line 301 in 8b99c43
* @param bool $should_autop Whether to apply wpautop to the block content output. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 302 in 8b99c43
* @param string|mixed $content The content to determine whether to autop. |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 87 characters
pods/src/Pods/Blocks/Types/Base.php
Line 302 in 8b99c43
* @param string|mixed $content The content to determine whether to autop. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 303 in 8b99c43
* @param array $attributes The Pods render attributes that will be used. |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 90 characters
pods/src/Pods/Blocks/Types/Base.php
Line 303 in 8b99c43
* @param array $attributes The Pods render attributes that will be used. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 304 in 8b99c43
*/ |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 305 in 8b99c43
return (bool) apply_filters( 'pods_blocks_should_autop', $should_autop, $content, $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 104 characters
pods/src/Pods/Blocks/Types/Base.php
Line 305 in 8b99c43
return (bool) apply_filters( 'pods_blocks_should_autop', $should_autop, $content, $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 306 in 8b99c43
} |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Field.php
Line 215 in 8b99c43
if ( $this->should_autop( $content, $attributes ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.ControlStructures.MultiLineCondition.SpacingAfterOpenBrace
First condition of a multi-line IF statement must directly follow the opening parenthesis
pods/src/Pods/Blocks/Types/Field.php
Line 215 in 8b99c43
if ( $this->should_autop( $content, $attributes ) ) { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Item_List.php
Line 429 in 8b99c43
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.ControlStructures.MultiLineCondition.SpacingAfterOpenBrace
First condition of a multi-line IF statement must directly follow the opening parenthesis
pods/src/Pods/Blocks/Types/Item_List.php
Line 429 in 8b99c43
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 103 characters
pods/src/Pods/Blocks/Types/Item_List.php
Line 429 in 8b99c43
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Item_List.php
Line 430 in 8b99c43
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 88 characters
pods/src/Pods/Blocks/Types/Item_List.php
Line 430 in 8b99c43
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Item_List.php
Line 431 in 8b99c43
} |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.ControlStructures.MultiLineCondition.SpacingAfterOpenBrace
First condition of a multi-line IF statement must directly follow the opening parenthesis
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 103 characters
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.TooLong
Line exceeds 85 characters; contains 88 characters
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 285 in 6dee8cc
$should_autop = ( |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 286 in 6dee8cc
is_string( $content ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 287 in 6dee8cc
&& false === strpos( $content, '<div' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 288 in 6dee8cc
&& false === strpos( $content, '<ul' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 289 in 6dee8cc
&& false === strpos( $content, '<ol' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 290 in 6dee8cc
&& false === strpos( $content, '<h' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 291 in 6dee8cc
&& false === strpos( $content, '<p' ) |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 292 in 6dee8cc
); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 294 in 6dee8cc
/** |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 295 in 6dee8cc
* Allow filtering whether to apply wpautop to the block content output. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 296 in 6dee8cc
* |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 297 in 6dee8cc
* This is used for things like Field block render or List block render of the no items found message. |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.MaxExceeded
Line exceeds maximum limit of 100 characters; contains 110 characters
pods/src/Pods/Blocks/Types/Base.php
Line 297 in 6dee8cc
* This is used for things like Field block render or List block render of the no items found message. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 298 in 6dee8cc
* |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 299 in 6dee8cc
* @since TBD |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 300 in 6dee8cc
* |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 301 in 6dee8cc
* @param bool $should_autop Whether to apply wpautop to the block content output. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 302 in 6dee8cc
* @param string|mixed $content The content to determine whether to autop. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 303 in 6dee8cc
* @param array $attributes The Pods render attributes that will be used. |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 304 in 6dee8cc
*/ |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 305 in 6dee8cc
return (bool) apply_filters( 'pods_blocks_should_autop', $should_autop, $content, $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.Formatting.NoSpaceAfterCast.SpaceFound
A cast statement must not be followed by a space
pods/src/Pods/Blocks/Types/Base.php
Line 305 in 6dee8cc
return (bool) apply_filters( 'pods_blocks_should_autop', $should_autop, $content, $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.MaxExceeded
Line exceeds maximum limit of 100 characters; contains 104 characters
pods/src/Pods/Blocks/Types/Base.php
Line 305 in 6dee8cc
return (bool) apply_filters( 'pods_blocks_should_autop', $should_autop, $content, $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Base.php
Line 306 in 6dee8cc
} |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Field.php
Line 215 in 6dee8cc
if ( $this->should_autop( $content, $attributes ) ) { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Item_List.php
Line 429 in 6dee8cc
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.MaxExceeded
Line exceeds maximum limit of 100 characters; contains 103 characters
pods/src/Pods/Blocks/Types/Item_List.php
Line 429 in 6dee8cc
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Item_List.php
Line 430 in 6dee8cc
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
pods/src/Pods/Blocks/Types/Item_List.php
Line 431 in 6dee8cc
} |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.Files.LineLength.MaxExceeded
Line exceeds maximum limit of 100 characters; contains 103 characters
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶Generic.WhiteSpace.DisallowTabIndent.TabsUsed
Spaces must be used to indent lines; tabs are not allowed
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket
Space after opening parenthesis of function call prohibited
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket
Expected 0 spaces before closing parenthesis; 1 found
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket
Space after opening parenthesis of function call prohibited
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket
Expected 0 spaces before closing parenthesis; 1 found
if ( ! empty( $attributes['not_found'] ) && $this->should_autop( $attributes['not_found'] ) ) { |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket
Space after opening parenthesis of function call prohibited
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket
Expected 0 spaces before closing parenthesis; 1 found
$attributes['not_found'] = wpautop( $attributes['not_found'], $attributes ); |
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$capability'.
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'pods_v'.
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
@@ -99,7 +99,7 @@ | |||
?> | |||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>" data-capability="<?php echo esc_attr( $capability ); ?>"> | |||
<?php | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_var_raw( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ | |||
echo PodsForm::field( 'capabilities[' . $capability . ']', pods_v( 'capabilities[' . $capability . ']', 'post', $checked ), 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
</a> | ||
</div> | ||
|
||
<div class="pods-wizard-option"> | ||
<div class="pods-wizard-option<?php echo ! empty( $quick_actions ) ? ' pods-wizard-option-with-secondary' : ''; ?>"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
|
||
<?php if ( ! empty( $quick_actions ) ) : ?> | ||
<div id="pods-wizard-quick-actions" | ||
<?php echo $submit_from_linked ? 'class="hidden"' : ''; ?>> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
@@ -569,6 +567,14 @@ | |||
</div> | |||
</div> | |||
</div> | |||
|
|||
<div id="pods-wizard-quick-actions-saving-in-progress" | |||
<?php echo ! $submit_from_linked ? 'class="hidden"' : ''; ?>> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
@@ -5,8 +5,12 @@ | |||
* @package Pods_templates | |||
*/ | |||
|
|||
$has_php = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$has_php".
if ( isset( $content ) ) { | ||
$has_php = false !== strpos( $content, '<?' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$has_php".
…new Migrate PHP component to assist in migrating PHP based pod pages/templates
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
<?php echo PodsForm::field( '_wpnonce', wp_create_nonce( 'pods-component-' . $component . '-' . $method ), 'hidden' ); ?> |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'wp_create_nonce'.
<?php echo PodsForm::field( '_wpnonce', wp_create_nonce( 'pods-component-' . $component . '-' . $method ), 'hidden' ); ?> |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
<?php echo PodsForm::field( '_wpnonce', wp_create_nonce( 'pods-component-' . $component . '-' . $method ), 'hidden' ); ?> |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$data".
pods/components/Migrate-PHP/ui/wizard.php
Line 61 in 17972ea
$data = $pod_templates; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$data_name".
pods/components/Migrate-PHP/ui/wizard.php
Line 62 in 17972ea
$data_name = 'templates'; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
pods/components/Migrate-PHP/ui/wizard.php
Line 80 in 17972ea
$zebra = false; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$item".
pods/components/Migrate-PHP/ui/wizard.php
Line 82 in 17972ea
foreach ( $data as $item ) { |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$checked".
pods/components/Migrate-PHP/ui/wizard.php
Line 83 in 17972ea
$checked = true; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$class".
pods/components/Migrate-PHP/ui/wizard.php
Line 85 in 17972ea
$class = ( $zebra ? 'even' : 'odd' ); |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 85 in 17972ea
$class = ( $zebra ? 'even' : 'odd' ); |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
pods/components/Migrate-PHP/ui/wizard.php
Line 87 in 17972ea
$zebra = ( ! $zebra ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['id']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$checked'.
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 91 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['name']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 92 in 17972ea
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 92 in 17972ea
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['label']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 92 in 17972ea
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
pods/components/Migrate-PHP/ui/wizard.php
Line 94 in 17972ea
] ); |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Migrate-PHP/ui/wizard.php
Line 94 in 17972ea
] ); |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$data".
pods/components/Migrate-PHP/ui/wizard.php
Line 109 in 17972ea
$data = $pod_pages; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$data_name".
pods/components/Migrate-PHP/ui/wizard.php
Line 110 in 17972ea
$data_name = 'pages'; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
pods/components/Migrate-PHP/ui/wizard.php
Line 128 in 17972ea
$zebra = false; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$item".
pods/components/Migrate-PHP/ui/wizard.php
Line 130 in 17972ea
foreach ( $data as $item ) { |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$checked".
pods/components/Migrate-PHP/ui/wizard.php
Line 131 in 17972ea
$checked = true; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$class".
pods/components/Migrate-PHP/ui/wizard.php
Line 133 in 17972ea
$class = ( $zebra ? 'even' : 'odd' ); |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 133 in 17972ea
$class = ( $zebra ? 'even' : 'odd' ); |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
pods/components/Migrate-PHP/ui/wizard.php
Line 135 in 17972ea
$zebra = ( ! $zebra ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['id']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$checked'.
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 139 in 17972ea
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['name']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 140 in 17972ea
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 140 in 17972ea
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['label']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 140 in 17972ea
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
pods/components/Migrate-PHP/ui/wizard.php
Line 142 in 17972ea
] ); |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Migrate-PHP/ui/wizard.php
Line 142 in 17972ea
] ); |
[phpcs] reported by reviewdog 🐶Universal.NamingConventions.NoReservedKeywordParameterNames.objectFound
It is recommended not to use reserved keyword "object" as function parameter name. Found: $object
Line 1058 in 17972ea
public static function object_to_page( Page $object ): array { |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.InlineComment.InvalidEndChar
Inline comments must end in full-stops, exclamation marks, or question marks
Line 1066 in 17972ea
// phpcode is deprecated |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1071 in 17972ea
'admin_only' => (boolean) get_post_meta( $id, 'admin_only', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1072 in 17972ea
'restrict_role' => (boolean) get_post_meta( $id, 'restrict_role', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1073 in 17972ea
'restrict_capability' => (boolean) get_post_meta( $id, 'restrict_capability', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1076 in 17972ea
'restrict_redirect' => (boolean) get_post_meta( $id, 'restrict_redirect', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1077 in 17972ea
'restrict_redirect_login' => (boolean) get_post_meta( $id, 'restrict_redirect_login', true ), |
[phpcs] reported by reviewdog 🐶Generic.Arrays.DisallowLongArraySyntax.Found
Short array syntax must be used to define arrays
pods/components/Templates/Templates.php
Line 714 in 17972ea
$default_templates = array( |
wp_enqueue_style( 'pods-wizard' ); | ||
} | ||
|
||
/** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.MissingParamTag
Doc comment for parameter "$options" missing
wp_enqueue_style( 'pods-wizard' ); | ||
} | ||
|
||
/** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.MissingParamTag
Doc comment for parameter "$component" missing
/** | ||
* Show the Admin | ||
* | ||
* @param $options |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.MissingParamType
Missing parameter type
* Show the Admin | ||
* | ||
* @param $options | ||
* @param $component |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.MissingParamType
Missing parameter type
if ( class_exists( 'Pods_Templates' ) ) { | ||
$pod_templates = array_filter( | ||
$api->load_templates(), | ||
static function( $object ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Functions.MultiLineFunctionDeclaration.SpaceAfterFunction
Expected 1 space after FUNCTION keyword; 0 found
<form action="" method="post" class="pods-submittable"> | ||
<div class="pods-submittable-fields"> | ||
<?php echo PodsForm::field( 'action', 'pods_admin_components', 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'component', $component, 'hidden' ); ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$component'.
<form action="" method="post" class="pods-submittable"> | ||
<div class="pods-submittable-fields"> | ||
<?php echo PodsForm::field( 'action', 'pods_admin_components', 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'component', $component, 'hidden' ); ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
<div class="pods-submittable-fields"> | ||
<?php echo PodsForm::field( 'action', 'pods_admin_components', 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'component', $component, 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'method', $method, 'hidden' ); ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
<div class="pods-submittable-fields"> | ||
<?php echo PodsForm::field( 'action', 'pods_admin_components', 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'component', $component, 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'method', $method, 'hidden' ); ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$method'.
<div class="pods-submittable-fields"> | ||
<?php echo PodsForm::field( 'action', 'pods_admin_components', 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'component', $component, 'hidden' ); ?> | ||
<?php echo PodsForm::field( 'method', $method, 'hidden' ); ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Migrate-PHP/ui/wizard.php
Line 103 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['id']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 103 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$checked'.
pods/components/Migrate-PHP/ui/wizard.php
Line 103 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 103 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 103 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 103 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['name']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 104 in 977d854
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 104 in 977d854
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['label']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 104 in 977d854
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
pods/components/Migrate-PHP/ui/wizard.php
Line 106 in 977d854
] ); |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Migrate-PHP/ui/wizard.php
Line 106 in 977d854
] ); |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$data".
pods/components/Migrate-PHP/ui/wizard.php
Line 121 in 977d854
$data = $pod_pages; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$data_name".
pods/components/Migrate-PHP/ui/wizard.php
Line 122 in 977d854
$data_name = 'pages'; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
pods/components/Migrate-PHP/ui/wizard.php
Line 140 in 977d854
$zebra = false; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$item".
pods/components/Migrate-PHP/ui/wizard.php
Line 142 in 977d854
foreach ( $data as $item ) { |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$checked".
pods/components/Migrate-PHP/ui/wizard.php
Line 143 in 977d854
$checked = true; |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$class".
pods/components/Migrate-PHP/ui/wizard.php
Line 145 in 977d854
$class = ( $zebra ? 'even' : 'odd' ); |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 145 in 977d854
$class = ( $zebra ? 'even' : 'odd' ); |
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
pods/components/Migrate-PHP/ui/wizard.php
Line 147 in 977d854
$zebra = ( ! $zebra ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['id']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$checked'.
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 977d854
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['name']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 152 in 977d854
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 152 in 977d854
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['label']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 152 in 977d854
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
pods/components/Migrate-PHP/ui/wizard.php
Line 154 in 977d854
] ); |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Migrate-PHP/ui/wizard.php
Line 154 in 977d854
] ); |
[phpcs] reported by reviewdog 🐶Universal.NamingConventions.NoReservedKeywordParameterNames.objectFound
It is recommended not to use reserved keyword "object" as function parameter name. Found: $object
Line 1058 in 977d854
public static function object_to_page( Page $object ): array { |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.InlineComment.InvalidEndChar
Inline comments must end in full-stops, exclamation marks, or question marks
Line 1066 in 977d854
// phpcode is deprecated |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1071 in 977d854
'admin_only' => (boolean) get_post_meta( $id, 'admin_only', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1072 in 977d854
'restrict_role' => (boolean) get_post_meta( $id, 'restrict_role', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1073 in 977d854
'restrict_capability' => (boolean) get_post_meta( $id, 'restrict_capability', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1076 in 977d854
'restrict_redirect' => (boolean) get_post_meta( $id, 'restrict_redirect', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1077 in 977d854
'restrict_redirect_login' => (boolean) get_post_meta( $id, 'restrict_redirect_login', true ), |
[phpcs] reported by reviewdog 🐶Generic.Arrays.DisallowLongArraySyntax.Found
Short array syntax must be used to define arrays
pods/components/Templates/Templates.php
Line 714 in 977d854
$default_templates = array( |
|
||
if ( isset( $params->templates ) && ! empty( $params->templates ) ) { | ||
foreach ( $params->templates as $object_id => $checked ) { | ||
if ( true === (boolean) $checked ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
|
||
if ( isset( $params->pages ) && ! empty( $params->pages ) ) { | ||
foreach ( $params->pages as $object_id => $checked ) { | ||
if ( true === (boolean) $checked ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
return $content; | ||
} | ||
|
||
private function setup_file_path( $file_path ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.Missing
Missing doc comment for function setup_file_path()
} | ||
} | ||
|
||
private function migrate_template( $object_id, bool $cleanup ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.Missing
Missing doc comment for function migrate_template()
|
||
if ( count( $files ) < 2 ) { | ||
// translators: %s is the file paths found. | ||
pods_error( sprintf( esc_html__( 'Unable to detect the file path: %s', 'pods' ), json_encode( $files, JSON_PRETTY_PRINT ) ) ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.WP.AlternativeFunctions.json_encode_json_encode
json_encode() is discouraged. Use wp_json_encode() instead.
$zebra = false; | ||
|
||
foreach ( $data as $item ) { | ||
$checked = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$checked".
foreach ( $data as $item ) { | ||
$checked = true; | ||
|
||
$class = ( $zebra ? 'even' : 'odd' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$class".
foreach ( $data as $item ) { | ||
$checked = true; | ||
|
||
$class = ( $zebra ? 'even' : 'odd' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
|
||
$class = ( $zebra ? 'even' : 'odd' ); | ||
|
||
$zebra = ( ! $zebra ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['id']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 099ba47
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$checked'.
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 099ba47
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 099ba47
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 099ba47
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Migrate-PHP/ui/wizard.php
Line 151 in 099ba47
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['name']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 152 in 099ba47
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
pods/components/Migrate-PHP/ui/wizard.php
Line 152 in 099ba47
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['label']'.
pods/components/Migrate-PHP/ui/wizard.php
Line 152 in 099ba47
'boolean_yes_label' => $item['name'] . ( ! empty( $item['label'] ) ? ' (' . $item['label'] . ')' : '' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
pods/components/Migrate-PHP/ui/wizard.php
Line 154 in 099ba47
] ); |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Migrate-PHP/ui/wizard.php
Line 154 in 099ba47
] ); |
[phpcs] reported by reviewdog 🐶Universal.NamingConventions.NoReservedKeywordParameterNames.objectFound
It is recommended not to use reserved keyword "object" as function parameter name. Found: $object
Line 1058 in 099ba47
public static function object_to_page( Page $object ): array { |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.InlineComment.InvalidEndChar
Inline comments must end in full-stops, exclamation marks, or question marks
Line 1066 in 099ba47
// phpcode is deprecated |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1071 in 099ba47
'admin_only' => (boolean) get_post_meta( $id, 'admin_only', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1072 in 099ba47
'restrict_role' => (boolean) get_post_meta( $id, 'restrict_role', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1073 in 099ba47
'restrict_capability' => (boolean) get_post_meta( $id, 'restrict_capability', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1076 in 099ba47
'restrict_redirect' => (boolean) get_post_meta( $id, 'restrict_redirect', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1077 in 099ba47
'restrict_redirect_login' => (boolean) get_post_meta( $id, 'restrict_redirect_login', true ), |
[phpcs] reported by reviewdog 🐶Generic.Arrays.DisallowLongArraySyntax.Found
Short array syntax must be used to define arrays
pods/components/Templates/Templates.php
Line 714 in 099ba47
$default_templates = array( |
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$item['id']'.
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$checked'.
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
foreach ( $data as $item ) { | ||
$checked = true; | ||
|
||
$class = ( $zebra ? 'even' : 'odd' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$class".
foreach ( $data as $item ) { | ||
$checked = true; | ||
|
||
$class = ( $zebra ? 'even' : 'odd' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
|
||
$class = ( $zebra ? 'even' : 'odd' ); | ||
|
||
$zebra = ( ! $zebra ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
Global variables defined by a theme/plugin should start with the theme/plugin prefix. Found: "$zebra".
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'PodsForm'.
?> | ||
<li class="pods-zebra-<?php echo esc_attr( $class ); ?>"> | ||
<?php | ||
echo PodsForm::field( $data_name . '[' . $item['id'] . ']', $checked, 'boolean', [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1110 in cc321eb
'restrict_redirect' => (boolean) get_post_meta( $id, 'restrict_redirect', true ), |
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
Line 1111 in cc321eb
'restrict_redirect_login' => (boolean) get_post_meta( $id, 'restrict_redirect_login', true ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not 'self'
pods/components/Templates/Templates.php
Line 645 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'self'.
pods/components/Templates/Templates.php
Line 645 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$obj'
pods/components/Templates/Templates.php
Line 645 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$obj'.
pods/components/Templates/Templates.php
Line 645 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not 'true'
pods/components/Templates/Templates.php
Line 645 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not 'self'
pods/components/Templates/Templates.php
Line 657 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'self'.
pods/components/Templates/Templates.php
Line 657 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$obj'
pods/components/Templates/Templates.php
Line 657 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$obj'.
pods/components/Templates/Templates.php
Line 657 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not 'true'
pods/components/Templates/Templates.php
Line 657 in cc321eb
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$template_output'
pods/components/Templates/Templates.php
Line 692 in cc321eb
echo $template_output; |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$template_output'.
pods/components/Templates/Templates.php
Line 692 in cc321eb
echo $template_output; |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$template_output'
pods/components/Templates/Templates.php
Line 710 in cc321eb
echo $template_output; |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$template_output'.
pods/components/Templates/Templates.php
Line 710 in cc321eb
echo $template_output; |
[phpcs] reported by reviewdog 🐶Generic.Arrays.DisallowLongArraySyntax.Found
Short array syntax must be used to define arrays
pods/components/Templates/Templates.php
Line 737 in cc321eb
$default_templates = array( |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Templates/Templates.php
Line 777 in cc321eb
$data = get_file_data( $file_path, [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Templates/Templates.php
Line 777 in cc321eb
$data = get_file_data( $file_path, [ |
[phpcs] reported by reviewdog 🐶WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned
Array double arrow not aligned correctly; expected 1 space(s) between "'PodTemplate'" and double arrow, but found 2.
pods/components/Templates/Templates.php
Line 778 in cc321eb
'PodTemplate' => 'Pod Template', |
[phpcs] reported by reviewdog 🐶WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned
Array double arrow not aligned correctly; expected 3 space(s) between "'MagicTags'" and double arrow, but found 1.
pods/components/Templates/Templates.php
Line 779 in cc321eb
'MagicTags' => 'Magic Tags', |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Templates/Templates.php
Line 780 in cc321eb
] ); |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.ParamCommentFullStop
Parameter comment must end with a full stop
pods/components/Templates/Templates.php
Line 793 in cc321eb
* @param string $code The template string to parse |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.ParamCommentFullStop
Parameter comment must end with a full stop
pods/components/Templates/Templates.php
Line 794 in cc321eb
* @param object $obj The Pods object |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'admin_url'.
admin_url( 'admin.php?page=pods-components' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
admin_url( 'admin.php?page=pods-components' ), |
$extra_headers = ''; | ||
|
||
if ( false !== strpos( $template_code, '{@' ) ) { | ||
$extra_headers = <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
|
||
} | ||
|
||
$contents = <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
} | ||
|
||
if ( $cleanup ) { | ||
$api->save_template( [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
$api->save_template( [ | ||
'id' => $object->get_id(), | ||
'code' => '', | ||
] ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
return str_replace( ABSPATH, '', $file_path ); | ||
} | ||
|
||
private function migrate_page( $object_id, bool $cleanup ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.Missing
Missing doc comment for function migrate_page()
'name' => 'precode_notice', | ||
'type' => 'html', | ||
'html_content' => sprintf( | ||
' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.Indent
Multi-line function call not indented correctly; expected 20 spaces but found 12
'name' => 'precode_notice', | ||
'type' => 'html', | ||
'html_content' => sprintf( | ||
' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Arrays.ArrayIndentation.MultiLineArrayItemNotAligned
Multi-line array item not aligned correctly; expected 16 spaces, but found 12
@@ -653,6 +696,93 @@ | |||
|
|||
add_action( 'admin_enqueue_scripts', array( $this, 'admin_assets' ), 21 ); | |||
add_filter( 'enter_title_here', array( $this, 'set_title_text' ), 10, 2 ); | |||
|
|||
$page_code = get_the_content(); | |||
$pre_code = get_post_meta( get_the_ID(), 'precode', true ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Generic.Formatting.MultipleStatementAlignment.NotSameWarning
Equals sign not aligned with surrounding assignments; expected 2 spaces but found 1 space
$page_code = get_the_content(); | ||
$pre_code = get_post_meta( get_the_ID(), 'precode', true ); | ||
|
||
$has_php = false !== strpos( $page_code, '<?' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Generic.Formatting.MultipleStatementAlignment.NotSameWarning
Equals sign not aligned with surrounding assignments; expected 5 spaces but found 1 space
* | ||
* @return array The Pod Page data array. | ||
*/ | ||
public static function object_to_page( Page $object ): array { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Universal.NamingConventions.NoReservedKeywordParameterNames.objectFound
It is recommended not to use reserved keyword "object" as function parameter name. Found: $object
…d Page content templates
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$obj'
pods/components/Templates/Templates.php
Line 657 in 8a9a3dc
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$obj'.
pods/components/Templates/Templates.php
Line 657 in 8a9a3dc
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not 'true'
pods/components/Templates/Templates.php
Line 657 in 8a9a3dc
echo self::do_template( $code, $obj, true ); |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$template_output'
pods/components/Templates/Templates.php
Line 692 in 8a9a3dc
echo $template_output; |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$template_output'.
pods/components/Templates/Templates.php
Line 692 in 8a9a3dc
echo $template_output; |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$template_output'
pods/components/Templates/Templates.php
Line 710 in 8a9a3dc
echo $template_output; |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$template_output'.
pods/components/Templates/Templates.php
Line 710 in 8a9a3dc
echo $template_output; |
[phpcs] reported by reviewdog 🐶Generic.Arrays.DisallowLongArraySyntax.Found
Short array syntax must be used to define arrays
pods/components/Templates/Templates.php
Line 737 in 8a9a3dc
$default_templates = array( |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Templates/Templates.php
Line 777 in 8a9a3dc
$data = get_file_data( $file_path, [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Templates/Templates.php
Line 777 in 8a9a3dc
$data = get_file_data( $file_path, [ |
[phpcs] reported by reviewdog 🐶WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned
Array double arrow not aligned correctly; expected 1 space(s) between "'PodTemplate'" and double arrow, but found 2.
pods/components/Templates/Templates.php
Line 778 in 8a9a3dc
'PodTemplate' => 'Pod Template', |
[phpcs] reported by reviewdog 🐶WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned
Array double arrow not aligned correctly; expected 3 space(s) between "'MagicTags'" and double arrow, but found 1.
pods/components/Templates/Templates.php
Line 779 in 8a9a3dc
'MagicTags' => 'Magic Tags', |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Templates/Templates.php
Line 780 in 8a9a3dc
] ); |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.ParamCommentFullStop
Parameter comment must end with a full stop
pods/components/Templates/Templates.php
Line 793 in 8a9a3dc
* @param string $code The template string to parse |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.ParamCommentFullStop
Parameter comment must end with a full stop
pods/components/Templates/Templates.php
Line 794 in 8a9a3dc
* @param object $obj The Pods object |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'admin_url'.
admin_url( 'admin.php?page=pods-components' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
admin_url( 'admin.php?page=pods-components' ), |
|
||
if ( count( $files ) < 2 ) { | ||
// translators: %s is the file paths found. | ||
pods_error( sprintf( esc_html__( 'Unable to detect the file path: %s', 'pods' ), json_encode( $files, JSON_PRETTY_PRINT ) ) ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.WP.AlternativeFunctions.json_encode_json_encode
json_encode() is discouraged. Use wp_json_encode() instead.
$precode_template = ''; | ||
|
||
if ( ! empty( $precode ) ) { | ||
$precode_template = "\n" . <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
$precode_has_end_tag = false !== strpos( $precode, '?>' ); | ||
|
||
if ( false === strpos( $template_code, '<?' ) ) { | ||
$template_code = "?>\n" . $template_code . ( ! $has_page_template ? '' : "\n<?php" ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.DisallowInlineIf.Found
Inline IF statements are not allowed
$start_tag = "\n<?php\n"; | ||
} | ||
|
||
$template_code = $start_tag . <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
$this->setup_file_path( $file_path_for_content ); | ||
|
||
if ( '_custom' !== $page_template && 'blank' !== $page_template ) { | ||
$extra_notes .= "\n" . <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
} | ||
|
||
if ( false !== strpos( $template_code, '{@' ) ) { | ||
$extra_headers = "\n" . <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
PHPTEMPLATE; | ||
} | ||
|
||
$contents = <<<PHPTEMPLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.PHP.Heredoc.NotAllowed
Use of heredoc and nowdoc syntax ("<<<") is not allowed; use standard strings or inline HTML instead
} | ||
|
||
if ( $cleanup ) { | ||
$api->save_page( [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
'name' => $object->get_label(), | ||
'code' => '', | ||
'precode' => '', | ||
] ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
return str_replace( ABSPATH, '', $file_path ); | ||
} | ||
|
||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR2.Classes.ClassDeclaration.CloseBraceAfterBody
The closing brace for the class must go on the next line after the body
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
phpcs
[phpcs] reported by reviewdog 🐶Generic.Arrays.DisallowLongArraySyntax.Found
Short array syntax must be used to define arrays
pods/components/Templates/Templates.php
Line 743 in e66ddd2
$default_templates = array( |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line
pods/components/Templates/Templates.php
Line 783 in e66ddd2
$data = get_file_data( $file_path, [ |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.MultipleArguments
Only one argument is allowed per line in a multi-line function call
pods/components/Templates/Templates.php
Line 783 in e66ddd2
$data = get_file_data( $file_path, [ |
[phpcs] reported by reviewdog 🐶WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned
Array double arrow not aligned correctly; expected 1 space(s) between "'PodTemplate'" and double arrow, but found 2.
pods/components/Templates/Templates.php
Line 784 in e66ddd2
'PodTemplate' => 'Pod Template', |
[phpcs] reported by reviewdog 🐶WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned
Array double arrow not aligned correctly; expected 3 space(s) between "'MagicTags'" and double arrow, but found 1.
pods/components/Templates/Templates.php
Line 785 in e66ddd2
'MagicTags' => 'Magic Tags', |
[phpcs] reported by reviewdog 🐶PEAR.Functions.FunctionCallSignature.CloseBracketLine
Closing parenthesis of a multi-line function call must be on a line by itself
pods/components/Templates/Templates.php
Line 786 in e66ddd2
] ); |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.ParamCommentFullStop
Parameter comment must end with a full stop
pods/components/Templates/Templates.php
Line 799 in e66ddd2
* @param string $code The template string to parse |
[phpcs] reported by reviewdog 🐶Squiz.Commenting.FunctionComment.ParamCommentFullStop
Parameter comment must end with a full stop
pods/components/Templates/Templates.php
Line 800 in e66ddd2
* @param object $obj The Pods object |
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'admin_url'.
admin_url( 'admin.php?page=pods-components' ), |
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not ')'
admin_url( 'admin.php?page=pods-components' ), |
'uri' => $object->get_label(), | ||
'code' => $object->get_description(), | ||
'phpcode' => $object->get_description(), | ||
// phpcode is deprecated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶Squiz.Commenting.InlineComment.InvalidEndChar
Inline comments must end in full-stops, exclamation marks, or question marks
'page_template' => get_post_meta( $id, 'page_template', true ), | ||
'title' => get_post_meta( $id, 'page_title', true ), | ||
'options' => [ | ||
'admin_only' => (boolean) get_post_meta( $id, 'admin_only', true ), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
'title' => get_post_meta( $id, 'page_title', true ), | ||
'options' => [ | ||
'admin_only' => (boolean) get_post_meta( $id, 'admin_only', true ), | ||
'restrict_role' => (boolean) get_post_meta( $id, 'restrict_role', true ), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
'options' => [ | ||
'admin_only' => (boolean) get_post_meta( $id, 'admin_only', true ), | ||
'restrict_role' => (boolean) get_post_meta( $id, 'restrict_role', true ), | ||
'restrict_capability' => (boolean) get_post_meta( $id, 'restrict_capability', true ), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
'restrict_capability' => (boolean) get_post_meta( $id, 'restrict_capability', true ), | ||
'roles_allowed' => get_post_meta( $id, 'roles_allowed', true ), | ||
'capability_allowed' => get_post_meta( $id, 'capability_allowed', true ), | ||
'restrict_redirect' => (boolean) get_post_meta( $id, 'restrict_redirect', true ), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶PSR12.Keywords.ShortFormTypeKeywords.LongFound
Short form type keywords must be used. Found: (boolean)
@@ -641,17 +667,13 @@ | |||
&& ! pods_access_bypass_private_post( $info ) | |||
) | |||
) { | |||
echo self::do_template( $code, $obj ); | |||
echo self::do_template( $code, $obj, true ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not 'true'
$template_output = self::do_template( $template_output, $obj ); | ||
} | ||
|
||
echo $template_output; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$template_output'
$template_output = self::do_template( $template_output, $obj ); | ||
} | ||
|
||
echo $template_output; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$template_output'.
$template_output = self::do_template( $template_output, $obj ); | ||
} | ||
|
||
echo $template_output; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶StellarWP.XSS.EscapeOutput.OutputNotEscaped
Expected next thing to be an escaping function (see Codex for 'Data Validation'), not '$template_output'
$template_output = self::do_template( $template_output, $obj ); | ||
} | ||
|
||
echo $template_output; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶WordPress.Security.EscapeOutput.OutputNotEscaped
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$template_output'.
GitHub API communication error. Please contact a human. (commit-ID: e66ddd2). |
Automated changes by create-pull-request GitHub action