Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
UserAdminV2
Overview
Overview
Details
Activity
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
庄欣
UserAdminV2
Commits
ed72448f
Commit
ed72448f
authored
Feb 17, 2012
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #343 from sparksp/patch-4
Consolidate Bundle::path and Bundle::location
parents
2296f63b
aa9d790a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
17 deletions
+9
-17
laravel/bundle.php
+8
-16
laravel/cli/tasks/bundle/bundler.php
+1
-1
No files found.
laravel/bundle.php
View file @
ed72448f
...
...
@@ -170,19 +170,6 @@ class Bundle {
}
/**
* Get the full path location of a given bundle.
*
* @param string $bundle
* @return string
*/
public
static
function
location
(
$bundle
)
{
$location
=
array_get
(
static
::
$bundles
,
$bundle
.
'.location'
);
return
path
(
'bundle'
)
.
str_finish
(
$location
,
DS
);
}
/**
* Determine if a given bundle has been started for the request.
*
* @param string $bundle
...
...
@@ -242,9 +229,14 @@ class Bundle {
*/
public
static
function
path
(
$bundle
)
{
if
(
is_null
(
$bundle
))
return
static
::
path
(
DEFAULT_BUNDLE
);
return
(
$bundle
==
DEFAULT_BUNDLE
)
?
path
(
'app'
)
:
static
::
location
(
$bundle
);
if
(
is_null
(
$bundle
)
or
$bundle
===
DEFAULT_BUNDLE
)
{
return
path
(
'app'
);
}
else
if
(
$location
=
array_get
(
static
::
$bundles
,
$bundle
.
'.location'
))
{
return
str_finish
(
path
(
'bundle'
)
.
$location
,
DS
);
}
}
/**
...
...
laravel/cli/tasks/bundle/bundler.php
View file @
ed72448f
...
...
@@ -81,7 +81,7 @@ class Bundler extends Task {
// First we want to retrieve the information for the bundle, such as
// where it is currently installed. This will allow us to upgrade
// the bundle into it's current installation path.
$location
=
Bundle
::
location
(
$name
);
$location
=
Bundle
::
path
(
$name
);
// If the bundle exists, we will grab the data about the bundle from
// the API so we can make the right bundle provider for the bundle,
...
...
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