2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-05 08:59:27 +08:00

FEATURE: Allow plugins to dynamically add seed fixture paths

This is useful if your plugin wants different seed data for different
locales for example.
This commit is contained in:
Robin Ward 2017-11-16 14:42:38 -05:00
parent 3d145a588f
commit 966c7e7f07
3 changed files with 23 additions and 2 deletions

View file

@ -340,6 +340,10 @@ class Plugin::Instance
seed_data[key] = value
end
def register_seed_path_builder(&block)
DiscoursePluginRegistry.register_seed_path_builder(&block)
end
def register_emoji(name, url)
Plugin::CustomEmoji.register(name, url)
end