You are here

public static function Helper::is_json in Anti Spam by CleanTalk 8.3

File

src/lib/Cleantalk/Common/Helper.php, line 347

Class

Helper
Cleantalk's hepler class

Namespace

Drupal\cleantalk\lib\Cleantalk\Common

Code

public static function is_json($string) {
  return is_string($string) && is_array(json_decode($string, true)) ? true : false;
}