mirror of
https://github.com/discourse/discourse.git
synced 2025-05-30 15:28:37 +08:00
Backwards compatibility with deprecation for Discourse.PostMenuView
This commit is contained in:
@ -108,10 +108,13 @@ module Tilt
|
||||
result = "Controller" if result == "ControllerController"
|
||||
result = "Route" if result == "DiscourseRoute"
|
||||
result = "View" if result == "ViewView"
|
||||
|
||||
result.gsub!(/Mixin$/, '')
|
||||
result.gsub!(/Model$/, '')
|
||||
|
||||
@output << "\n\nDiscourse.#{result} = require('#{require_name}').default;\n"
|
||||
if result != "PostMenuView"
|
||||
@output << "\n\nDiscourse.#{result} = require('#{require_name}').default;\n"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user