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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
0a841ce6
Commit
0a841ce6
authored
May 21, 2021
by
Jackie Fraser
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix invite group button showing when signed out
parent
cb611101
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
1 deletion
+9
-1
app/helpers/invite_members_helper.rb
app/helpers/invite_members_helper.rb
+1
-1
spec/features/projects/members/invite_group_spec.rb
spec/features/projects/members/invite_group_spec.rb
+8
-0
No files found.
app/helpers/invite_members_helper.rb
View file @
0a841ce6
...
...
@@ -8,7 +8,7 @@ module InviteMembersHelper
end
def
can_invite_group_for_project?
(
project
)
Feature
.
enabled?
(
:invite_members_group_modal
,
project
.
group
)
&&
project
.
allowed_to_share_with_group?
Feature
.
enabled?
(
:invite_members_group_modal
,
project
.
group
)
&&
can_manage_project_members?
(
project
)
&&
project
.
allowed_to_share_with_group?
end
def
directly_invite_members?
...
...
spec/features/projects/members/invite_group_spec.rb
View file @
0a841ce6
...
...
@@ -32,6 +32,14 @@ RSpec.describe 'Project > Members > Invite group', :js do
expect
(
page
).
to
have_selector
(
expected_invite_group_selector
)
end
it
'does not display either the form or the button when visiting the page not signed in'
do
project
=
create
(
:project
,
namespace:
create
(
:group
))
visit
project_project_members_path
(
project
)
expect
(
page
).
not_to
have_selector
(
expected_invite_group_selector
)
end
end
describe
'Share with group lock'
do
...
...
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