diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2017-10-25 15:39:23 +0300 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2017-10-25 15:39:23 +0300 |
commit | 47c5ecaff33f49cfdc5fd47f5baff9a13e3d3807 (patch) | |
tree | 8352b7ec74351f1324956a4c7c34c32a812816f1 /lib/api/helpers.rb | |
parent | 188e1c261edf70685a7ea9e4276cd9794f2029c3 (diff) | |
parent | e81d74b9253e4a9f48bad0071bf37075bb6a20c5 (diff) | |
download | gitlab-ce-use-git-branch-merged.tar.gz |
Merge remote-tracking branch 'upstream/master' into use-git-branch-mergeduse-git-branch-merged
* upstream/master: (56 commits)
Resolve "Remove overzealous tooltips in projects page tabs"
Remove filter icon from search bar
Don't rename groups/projects that aren't reserved anymore
Memoize GitLab logger to reduce open file descriptors
Update groups API documentation
Changing the smallest of typos
Remove `<script>` and `<template>` from CHANGELOG.md
Support `Gitaly::User`'s gl_username field
Fix icon color and btn-group alignment of discussion buttons
Simple docs fixes
Fix button type
Changes after review
fixed karma tests
Removes group_avatar & group_label_subscription from global namespace
Fix CSS in load more participants
Fix the description of the new branch created by an issue's new branch button
Fix a small typo in the delete merged branches documentation
spec fixes
Remove Sherlock usage from the performance bar
moved to eventHub to manage creating new files removed an ID from the CSS
...
Diffstat (limited to 'lib/api/helpers.rb')
-rw-r--r-- | lib/api/helpers.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/api/helpers.rb b/lib/api/helpers.rb index 2b316b58ed9..7a2ec865860 100644 --- a/lib/api/helpers.rb +++ b/lib/api/helpers.rb @@ -184,6 +184,10 @@ module API end end + def require_pages_enabled! + not_found! unless user_project.pages_available? + end + def can?(object, action, subject = :global) Ability.allowed?(object, action, subject) end |