diff --git a/app/controllers/list_controller.rb b/app/controllers/list_controller.rb index 635d6a1dd15..69048ea828c 100644 --- a/app/controllers/list_controller.rb +++ b/app/controllers/list_controller.rb @@ -35,6 +35,10 @@ class ListController < ApplicationController if request_is_for_uncategorized? list = query.list_uncategorized else + if !@category + raise Discourse::NotFound + return + end guardian.ensure_can_see!(@category) list = query.list_category(@category) end