Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Jérome Perrin
gitlab-ce
Commits
00408f37
Commit
00408f37
authored
Feb 20, 2015
by
Douwe Maan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move 'require_non_empty_project' filter to front so 'assign_ref_vars' doesn't 404.
parent
6b0199ff
Changes
13
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
12 additions
and
13 deletions
+12
-13
app/controllers/projects/blame_controller.rb
app/controllers/projects/blame_controller.rb
+1
-1
app/controllers/projects/blob_controller.rb
app/controllers/projects/blob_controller.rb
+1
-1
app/controllers/projects/branches_controller.rb
app/controllers/projects/branches_controller.rb
+0
-1
app/controllers/projects/commit_controller.rb
app/controllers/projects/commit_controller.rb
+1
-1
app/controllers/projects/commits_controller.rb
app/controllers/projects/commits_controller.rb
+1
-1
app/controllers/projects/compare_controller.rb
app/controllers/projects/compare_controller.rb
+1
-1
app/controllers/projects/forks_controller.rb
app/controllers/projects/forks_controller.rb
+1
-1
app/controllers/projects/graphs_controller.rb
app/controllers/projects/graphs_controller.rb
+1
-1
app/controllers/projects/network_controller.rb
app/controllers/projects/network_controller.rb
+1
-1
app/controllers/projects/raw_controller.rb
app/controllers/projects/raw_controller.rb
+1
-1
app/controllers/projects/refs_controller.rb
app/controllers/projects/refs_controller.rb
+1
-1
app/controllers/projects/repositories_controller.rb
app/controllers/projects/repositories_controller.rb
+1
-1
app/controllers/projects/tree_controller.rb
app/controllers/projects/tree_controller.rb
+1
-1
No files found.
app/controllers/projects/blame_controller.rb
View file @
00408f37
...
...
@@ -2,9 +2,9 @@
class
Projects::BlameController
<
Projects
::
ApplicationController
include
ExtractsPath
before_filter
:require_non_empty_project
before_filter
:assign_ref_vars
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
def
show
@blob
=
@repository
.
blob_at
(
@commit
.
id
,
@path
)
...
...
app/controllers/projects/blob_controller.rb
View file @
00408f37
...
...
@@ -5,8 +5,8 @@ class Projects::BlobController < Projects::ApplicationController
# Raised when given an invalid file path
class
InvalidPathError
<
StandardError
;
end
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
,
except:
[
:new
,
:create
]
before_filter
:authorize_download_code!
before_filter
:authorize_push_code!
,
only:
[
:destroy
]
before_filter
:assign_blob_vars
before_filter
:commit
,
except:
[
:new
,
:create
]
...
...
app/controllers/projects/branches_controller.rb
View file @
00408f37
...
...
@@ -2,7 +2,6 @@ class Projects::BranchesController < Projects::ApplicationController
include
ActionView
::
Helpers
::
SanitizeHelper
# Authorize
before_filter
:require_non_empty_project
before_filter
:authorize_download_code!
before_filter
:authorize_push_code!
,
only:
[
:create
,
:destroy
]
...
...
app/controllers/projects/commit_controller.rb
View file @
00408f37
...
...
@@ -3,8 +3,8 @@
# Not to be confused with CommitsController, plural.
class
Projects::CommitController
<
Projects
::
ApplicationController
# Authorize
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
before_filter
:authorize_download_code!
before_filter
:commit
def
show
...
...
app/controllers/projects/commits_controller.rb
View file @
00408f37
...
...
@@ -3,9 +3,9 @@ require "base64"
class
Projects::CommitsController
<
Projects
::
ApplicationController
include
ExtractsPath
before_filter
:require_non_empty_project
before_filter
:assign_ref_vars
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
def
show
@repo
=
@project
.
repository
...
...
app/controllers/projects/compare_controller.rb
View file @
00408f37
class
Projects::CompareController
<
Projects
::
ApplicationController
# Authorize
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
before_filter
:authorize_download_code!
def
index
end
...
...
app/controllers/projects/forks_controller.rb
View file @
00408f37
class
Projects::ForksController
<
Projects
::
ApplicationController
# Authorize
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
before_filter
:authorize_download_code!
def
new
@namespaces
=
current_user
.
manageable_namespaces
...
...
app/controllers/projects/graphs_controller.rb
View file @
00408f37
class
Projects::GraphsController
<
Projects
::
ApplicationController
# Authorize
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
before_filter
:authorize_download_code!
def
show
respond_to
do
|
format
|
...
...
app/controllers/projects/network_controller.rb
View file @
00408f37
...
...
@@ -2,9 +2,9 @@ class Projects::NetworkController < Projects::ApplicationController
include
ExtractsPath
include
ApplicationHelper
before_filter
:require_non_empty_project
before_filter
:assign_ref_vars
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
def
show
respond_to
do
|
format
|
...
...
app/controllers/projects/raw_controller.rb
View file @
00408f37
...
...
@@ -2,9 +2,9 @@
class
Projects::RawController
<
Projects
::
ApplicationController
include
ExtractsPath
before_filter
:require_non_empty_project
before_filter
:assign_ref_vars
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
def
show
@blob
=
@repository
.
blob_at
(
@commit
.
id
,
@path
)
...
...
app/controllers/projects/refs_controller.rb
View file @
00408f37
class
Projects::RefsController
<
Projects
::
ApplicationController
include
ExtractsPath
before_filter
:require_non_empty_project
before_filter
:assign_ref_vars
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
def
switch
respond_to
do
|
format
|
...
...
app/controllers/projects/repositories_controller.rb
View file @
00408f37
class
Projects::RepositoriesController
<
Projects
::
ApplicationController
# Authorize
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
,
except: :create
before_filter
:authorize_download_code!
before_filter
:authorize_admin_project!
,
only: :create
def
create
...
...
app/controllers/projects/tree_controller.rb
View file @
00408f37
...
...
@@ -2,9 +2,9 @@
class
Projects::TreeController
<
Projects
::
ApplicationController
include
ExtractsPath
before_filter
:require_non_empty_project
,
except:
[
:new
,
:create
]
before_filter
:assign_ref_vars
before_filter
:authorize_download_code!
before_filter
:require_non_empty_project
,
except:
[
:new
,
:create
]
def
show
if
tree
.
entries
.
empty?
...
...
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