<?php /** * Created by PhpStorm. * User: prasi * Date: 21/11/15 * Time: 4:06 PM */ include_once '../DB/DBManager.php'; include_once '../FrontEnd/CrashManager.php'; if (DBManager::$debug) { error_reporting(E_ALL); ini_set('display_errors', 1); } else { ini_set('display_errors', 0); } $email = $_REQUEST['email']; $crash_report = $_REQUEST['crash_report']; if ($crash_report != null) { echo json_encode(CrashManager::reportCrash($email, $crash_report)); }
public static function reportCrash($email, $crash_report) { CrashManager::storeCrashReport($email, $crash_report); return CrashManager::emailCrashReport($email, $crash_report); }