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
871fc894
Commit
871fc894
authored
Aug 30, 2017
by
Michael Kozono
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Prevent more sync jobs if already pending
parent
3f4c9e98
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
app/controllers/groups/ldaps_controller.rb
app/controllers/groups/ldaps_controller.rb
+7
-3
No files found.
app/controllers/groups/ldaps_controller.rb
View file @
871fc894
...
@@ -3,9 +3,13 @@ class Groups::LdapsController < Groups::ApplicationController
...
@@ -3,9 +3,13 @@ class Groups::LdapsController < Groups::ApplicationController
before_action
:authorize_admin_group!
before_action
:authorize_admin_group!
def
sync
def
sync
@group
.
pending_ldap_sync
if
@group
.
pending_ldap_sync
LdapGroupSyncWorker
.
perform_async
(
@group
.
id
)
LdapGroupSyncWorker
.
perform_async
(
@group
.
id
)
message
=
'The group sync has been scheduled'
else
message
=
'The group sync is already scheduled'
end
redirect_to
group_group_members_path
(
@group
),
notice:
'The group sync has been scheduled'
redirect_to
group_group_members_path
(
@group
),
notice:
message
end
end
end
end
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