FIX: Backwards compatibility for older Discourse versions (#143)

This commit is contained in:
Mark VanLandingham 2021-06-24 01:41:51 -05:00 committed by GitHub
parent 52d4656011
commit eac6539c46
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -634,7 +634,9 @@ SQL
AND di.period_type = :period_type AND di.period_type = :period_type
AND di.solutions <> x.solutions AND di.solutions <> x.solutions
" "
add_directory_column("solutions", query: query) if respond_to?(:add_directory_column)
add_directory_column("solutions", query: query)
end
add_to_class(:composer_messages_finder, :check_topic_is_solved) do add_to_class(:composer_messages_finder, :check_topic_is_solved) do
return if !SiteSetting.solved_enabled || SiteSetting.disable_solved_education_message return if !SiteSetting.solved_enabled || SiteSetting.disable_solved_education_message