Skip to content

Commit

Permalink
linting
Browse files Browse the repository at this point in the history
  • Loading branch information
oblakeerickson committed May 8, 2024
1 parent 2330125 commit cd72f00
Showing 1 changed file with 29 additions and 28 deletions.
57 changes: 29 additions & 28 deletions lib/discourse_api/api/categories.rb
Original file line number Diff line number Diff line change
Expand Up @@ -100,34 +100,35 @@ def category_set_user_notification_level(category_id, params)
def common_category_params(args, include_id: false)
params = API.params(args)
params = params.required(:id) if include_id
params.required(:name)
.optional(
:color,
:text_color,
:slug,
:permissions,
:auto_close_hours,
:auto_close_based_on_last_post,
:position,
:email_in,
:email_in_allow_strangers,
:logo_url,
:background_url,
:allow_badges,
:topic_template,
:custom_fields,
:description,
:reviewable_by_group_name,
:show_subcategory_list,
:subcategory_list_style,
:allowed_tags,
:allowed_tag_groups,
:required_tag_group_name,
:topic_featured_links_allowed,
:search_priority,
:form_template_ids
)
.default(parent_category_id: nil)
params
.required(:name)
.optional(
:color,
:text_color,
:slug,
:permissions,
:auto_close_hours,
:auto_close_based_on_last_post,
:position,
:email_in,
:email_in_allow_strangers,
:logo_url,
:background_url,
:allow_badges,
:topic_template,
:custom_fields,
:description,
:reviewable_by_group_name,
:show_subcategory_list,
:subcategory_list_style,
:allowed_tags,
:allowed_tag_groups,
:required_tag_group_name,
:topic_featured_links_allowed,
:search_priority,
:form_template_ids,
)
.default(parent_category_id: nil)
end
end
end
Expand Down

0 comments on commit cd72f00

Please sign in to comment.