Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add parameters #37

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions src/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,49 +3,49 @@
use Rareloop\Lumberjack\Helpers;

if (!function_exists('app')) {
function app()
function app($key = null)
{
return call_user_func_array([Helpers::class, 'app'], func_get_args());
}
}

if (!function_exists('config')) {
function config()
function config($key, $default = null)
{
return call_user_func_array([Helpers::class, 'config'], func_get_args());
}
}

if (!function_exists('view')) {
function view()
function view($template, $context = [], $statusCode = 200, $headers = [])
{
return call_user_func_array([Helpers::class, 'view'], func_get_args());
}
}

if (!function_exists('route')) {
function route()
function route($name, $params = [])
{
return call_user_func_array([Helpers::class, 'route'], func_get_args());
}
}

if (!function_exists('redirect')) {
function redirect()
function redirect($url, $statusCode = 302, $headers = [])
{
return call_user_func_array([Helpers::class, 'redirect'], func_get_args());
}
}

if (!function_exists('report')) {
function report()
function report(Exception $e)
{
return call_user_func_array([Helpers::class, 'report'], func_get_args());
}
}

if (!function_exists('session')) {
function session()
function session($key = null, $default = null)
{
return call_user_func_array([Helpers::class, 'session'], func_get_args());
}
Expand All @@ -66,7 +66,7 @@ function request()
}

if (!function_exists('logger')) {
function logger()
function logger($message = null, $context = [])
{
return call_user_func_array([Helpers::class, 'logger'], func_get_args());
}
Expand Down