← All changes
|
vendor/woocommerce/action-scheduler/classes/ActionScheduler_InvalidActionException.php
+4
-4
1.4.0
→
trunk
View file →
| @@ -12,8 +12,9 @@ | ||
| 12 | 12 | /** |
| 13 | 13 | * Create a new exception when the action's schedule cannot be fetched. |
| 14 | 14 | * |
| 15 | 15 | * @param string $action_id The action ID with bad args. |
| 16 | + * @param mixed $schedule Passed schedule. | |
| 16 | 17 | * @return static |
| 17 | 18 | */ |
| 18 | 19 | public static function from_schedule( $action_id, $schedule ) { |
| 19 | 20 | $message = sprintf( |
| @@ -19,9 +20,9 @@ | ||
| 19 | 20 | $message = sprintf( |
| 20 | 21 | /* translators: 1: action ID 2: schedule */ |
| 21 | 22 | __( 'Action [%1$s] has an invalid schedule: %2$s', 'action-scheduler' ), |
| 22 | 23 | $action_id, |
| 23 | - var_export( $schedule, true ) | |
| 24 | + var_export( $schedule, true ) // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_var_export | |
| 24 | 25 | ); |
| 25 | 26 | |
| 26 | 27 | return new static( $message ); |
| 27 | 28 | } |
| @@ -28,11 +29,10 @@ | ||
| 28 | 29 | |
| 29 | 30 | /** |
| 30 | 31 | * Create a new exception when the action's args cannot be decoded to an array. |
| 31 | 32 | * |
| 32 | - * @author Jeremy Pry | |
| 33 | - * | |
| 34 | 33 | * @param string $action_id The action ID with bad args. |
| 34 | + * @param mixed $args Passed arguments. | |
| 35 | 35 | * @return static |
| 36 | 36 | */ |
| 37 | 37 | public static function from_decoding_args( $action_id, $args = array() ) { |
| 38 | 38 | $message = sprintf( |
| @@ -38,9 +38,9 @@ | ||
| 38 | 38 | $message = sprintf( |
| 39 | 39 | /* translators: 1: action ID 2: arguments */ |
| 40 | 40 | __( 'Action [%1$s] has invalid arguments. It cannot be JSON decoded to an array. $args = %2$s', 'action-scheduler' ), |
| 41 | 41 | $action_id, |
| 42 | - var_export( $args, true ) | |
| 42 | + var_export( $args, true ) // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_var_export | |
| 43 | 43 | ); |
| 44 | 44 | |
| 45 | 45 | return new static( $message ); |
| 46 | 46 | } |