Skip to content
Snippets Groups Projects
Unverified Commit 94f31ccc authored by Mike Greiling's avatar Mike Greiling
Browse files

fix issue in which projects which have forks cannot be changed from private to public

parent 7fa0a3e7
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -148,7 +148,7 @@ module ProjectsHelper
def can_change_visibility_level?(project, current_user)
return false unless can?(current_user, :change_visibility_level, project)
 
if project.fork_source
if project.forked? && project.fork_source
project.fork_source.visibility_level > Gitlab::VisibilityLevel::PRIVATE
else
true
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment