Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
4dc7f944
Commit
4dc7f944
authored
Aug 08, 2011
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor the configuration class.
parent
86fde936
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
config.php
system/config.php
+3
-2
No files found.
system/config.php
View file @
4dc7f944
...
...
@@ -93,6 +93,9 @@ class Config {
/**
* Load all of the configuration items from a file.
*
* Laravel supports environment specific configuration files. So, the base configuration
* array will be loaded first, then any environment specific options will be merged in.
*
* @param string $file
* @param string $module
* @return bool
...
...
@@ -103,10 +106,8 @@ class Config {
$path
=
(
$module
===
'application'
)
?
CONFIG_PATH
:
MODULE_PATH
.
$module
.
'/config/'
;
// Load the base configuration items from the application directory.
$config
=
(
file_exists
(
$base
=
$path
.
$file
.
EXT
))
?
require
$base
:
array
();
// Merge any environment specific configuration into the base array.
if
(
isset
(
$_SERVER
[
'LARAVEL_ENV'
])
and
file_exists
(
$path
=
$path
.
$_SERVER
[
'LARAVEL_ENV'
]
.
'/'
.
$file
.
EXT
))
{
$config
=
array_merge
(
$config
,
require
$path
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment