<?php

namespace App\Http\Controllers;

use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Routing\Controller as BaseController;
use Illuminate\Http\JsonResponse;

class Controller extends BaseController
{
    use AuthorizesRequests, ValidatesRequests;

    protected function ReturnResponse(bool $status, string $message="", array $data=[],  int $status_code=200): JsonResponse
    {
        return response()->json(['success' => $status, 'message' =>  $message, 'data' => $data], $status_code);
    }
}
