Skip to content

Commit

Permalink
Merge pull request #17 from chrisolesen/master
Browse files Browse the repository at this point in the history
Handle single quotes
  • Loading branch information
kennym authored Jun 3, 2020
2 parents 4ee8db3 + 3bec9c8 commit 9bc859e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion contact-form-7-api.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Plugin Name: Contact form 7 to api + Basic auth
* Plugin URI: https://github.com/kennym/cf7-to-api
* Description: Connect contact forms 7 to remote API using GET or POST.
* Version: 1.4.5
* Version: 1.4.6
* Author: Kenny Meyer
* Author URI: https://www.kennymeyer.net
* License: GPL-2.0+
Expand Down
4 changes: 2 additions & 2 deletions includes/class-cf7-api-admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,7 @@ private function send_lead( $record , $debug = false , $method = 'GET' , $record

$args['headers']['Content-Type'] = 'application/json';

$json = $this->parse_json( $lead );
$json = $this->parse_json( stripslashes ( $lead ) );

if( is_wp_error( $json ) ){
return $json;
Expand Down Expand Up @@ -623,7 +623,7 @@ private function send_lead( $record , $debug = false , $method = 'GET' , $record

$args['headers']['Content-Type'] = 'application/json';

$json = $this->parse_json( $lead );
$json = $this->parse_json( stripslashes( $lead ) );

if( is_wp_error( $json ) ){
return $json;
Expand Down
4 changes: 4 additions & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@ For example:
Changelog
---------

### 1.4.6

- Handle single quotes

### 1.4.5

- Handle line breaks
Expand Down

0 comments on commit 9bc859e

Please sign in to comment.