Update incident.php

This commit is contained in:
Yiğit Kerem Oktay 2020-10-01 16:35:32 +03:00 committed by GitHub
parent 38fcabdbb4
commit 671004579c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -78,13 +78,9 @@ class Incident implements JsonSerializable
* for char limits. * for char limits.
* @return void * @return void
*/ */
public static function add() public static function add($user_id = $_SESSION['user'],$type = $_POST['type'],$title = strip_tags($_POST['title']),$text = strip_tags($_POST['text'], '<br>'))
{ {
global $mysqli, $message; global $mysqli, $message;
$user_id = $_SESSION['user'];
$type = $_POST['type'];
$title = strip_tags($_POST['title']);
$text = strip_tags($_POST['text'], '<br>');
if (strlen($title)==0) if (strlen($title)==0)
{ {