Skip to content

Commit

Permalink
Allow changing repositories for package maintainer
Browse files Browse the repository at this point in the history
Allow a user to enable or disable the repositories of a package he or
she is mantainer of.

Fixes #8110.
  • Loading branch information
eduardoj committed Aug 26, 2019
1 parent 1048038 commit 6d318fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/app/controllers/webui/repositories_controller.rb
Expand Up @@ -14,7 +14,7 @@ def index
@available_architectures = Architecture.available
@repositories = @project.repositories.preload({ path_elements: { link: :project } }, :architectures)
@repositories = @repositories.includes(:download_repositories)
@user_can_modify = policy(@project).update?
@user_can_modify = @package.present? ? policy(@package).update? : policy(@project).update?
if switch_to_webui2
@flags = {}
[:build, :debuginfo, :publish, :useforbuild].each do |flag_type|
Expand Down

0 comments on commit 6d318fc

Please sign in to comment.