Skip to content

Commit

Permalink
updated
Browse files Browse the repository at this point in the history
  • Loading branch information
juancristobalgd1 authored Nov 11, 2023
1 parent 7f399ff commit fbc575d
Showing 1 changed file with 12 additions and 14 deletions.
26 changes: 12 additions & 14 deletions src/axm_helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -278,23 +278,10 @@ function randomId($size = 50)
*/
function lang(string $key, array $args = [])
{
// Get the message translation using the provided key.
// $message = Lang::gettext($key);

// // Check if multiple parameters are passed.
// if (func_num_args() > 1) {
// $args = func_get_args();
// unset($args[0]);
// // Replace placeholders in the message using vsprintf.
// $message = vsprintf($message, $args);
// }

// return $message;

// Get an instance of Lang
$lang = Lang::make();

if (emty($args)) {
if (empty($args)) {
return $lang->trans('file.message');
}

Expand Down Expand Up @@ -364,6 +351,17 @@ function baseUrl(string $dir = ''): string
}
}

if (!function_exists('asset')) {

function asset(string $dirFile): string
{
$pathAssets = 'resources/assets/';
$file = baseUrl($pathAssets.$dirFile);

return $file;
}
}

if (!function_exists('go')) {

/**
Expand Down

0 comments on commit fbc575d

Please sign in to comment.