forked from External/greenlight
		
	master #1
@@ -59,4 +59,11 @@ module RoomsHelper
 | 
				
			|||||||
  def hidden_format_public
 | 
					  def hidden_format_public
 | 
				
			||||||
    ENV.fetch("HIDDEN_FORMATS_PUBLIC", "").split(",")
 | 
					    ENV.fetch("HIDDEN_FORMATS_PUBLIC", "").split(",")
 | 
				
			||||||
  end
 | 
					  end
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # Returns the total number of visibile rooms for the current user
 | 
				
			||||||
 | 
					  def total_room_count(user)
 | 
				
			||||||
 | 
					    total = user.rooms.length
 | 
				
			||||||
 | 
					    total += user.shared_rooms.length if shared_access_allowed
 | 
				
			||||||
 | 
					    total
 | 
				
			||||||
 | 
					  end
 | 
				
			||||||
end
 | 
					end
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -82,7 +82,7 @@
 | 
				
			|||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <% if current_user.ordered_rooms.length > 5 %>
 | 
					    <% if total_room_count(current_user) > 5 %>
 | 
				
			||||||
      <div class="input-icon invite-link-input mb-3">
 | 
					      <div class="input-icon invite-link-input mb-3">
 | 
				
			||||||
        <span class="input-icon-addon">
 | 
					        <span class="input-icon-addon">
 | 
				
			||||||
          <i class="fas fa-search"></i>
 | 
					          <i class="fas fa-search"></i>
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user