Skip to content

Commit

Permalink
コメントのみ
Browse files Browse the repository at this point in the history
  • Loading branch information
kurudrive committed Jul 29, 2024
1 parent 8e27091 commit 5f279eb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion inc/call-to-action/package/class-vk-call-to-action.php
Original file line number Diff line number Diff line change
Expand Up @@ -200,13 +200,15 @@ public static function save_custom_field( $post_id ) {
if ( isset( $_POST[ $custom_field_name ] ) ) {
if ( ! empty( $custom_field_name['escape_type'] ) ) {
if ( is_array( $custom_field_name['escape_type'] ) ) {
// エスケープ処理が複数ある場合
$data = $_POST[ $custom_field_name ];
foreach ( $custom_field_name['escape_type'] as $escape ) {
$data = call_user_func( $escape, $data );
}
} else {
// エスケープ処理が一つの場合
$data = call_user_func( $custom_field_name['escape_type'], $_POST[ $custom_field_name ] );
}
}
} else {
$data = $_POST[ $custom_field_name ];
}
Expand Down

0 comments on commit 5f279eb

Please sign in to comment.