Skip to content

Commit

Permalink
[WiP] Save current progress
Browse files Browse the repository at this point in the history
  • Loading branch information
HardeepAsrani committed Jan 22, 2024
1 parent ad39726 commit 67869c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions inc/class-api.php
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ public function images( \WP_REST_Request $request ) {
*
* @param array $data Response.
*
* @return array|bool
* @return array|false
*/
private static function process_json_from_response( $data ) {
// Find the target item.
Expand All @@ -407,7 +407,7 @@ private static function process_json_from_response( $data ) {
try {
$json_object = json_decode( $json_string, true );
return $json_object;
} catch ( \Exception $e) {
} catch ( \Exception $e ) {
// If parsing failed, try to find a JSON array in the string.
preg_match( '/\[(.|\n)*\]/', $json_string, $matches );

Expand Down

0 comments on commit 67869c5

Please sign in to comment.