DEV: Instance#replace_flags block should be optional

This commit is contained in:
romanrizzi 2020-07-03 16:21:06 -03:00
parent 48b4ed41f5
commit 6b4cebed3e

View File

@ -151,7 +151,7 @@ class Plugin::Instance
def replace_flags(settings: ::FlagSettings.new, score_type_names: [])
next_flag_id = ReviewableScore.types.values.max + 1
yield(settings, next_flag_id)
yield(settings, next_flag_id) if block_given?
reloadable_patch do |plugin|
::PostActionType.replace_flag_settings(settings)