Skip to content

Commit 63c0fed

Browse files
committed
Merge pull request #7117 from brunogaspar/patch-1
[5.0] Added a config_path() helper function
2 parents b259c11 + e124081 commit 63c0fed

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/Illuminate/Foundation/helpers.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,20 @@ function config($key = null, $default = null)
164164
}
165165
}
166166

167+
if ( ! function_exists('config_path'))
168+
{
169+
/**
170+
* Get the configuration path.
171+
*
172+
* @param string $path
173+
* @return string
174+
*/
175+
function config_path($path = '')
176+
{
177+
return app()->make('path.config').($path ? '/'.$path : $path);
178+
}
179+
}
180+
167181
if ( ! function_exists('cookie'))
168182
{
169183
/**

0 commit comments

Comments
 (0)