I can't use plugin when i add this class to proejct:
Componentpublic class PluginEnabledListener implements InitializingBean, DisposableBean {@JiraImport private final EventPublisher eventPublisher; @Autowired public PluginEnabledListener(EventPublisher eventPublisher) {this.eventPublisher = eventPublisher; }@Override public void destroy() throws Exception {eventPublisher.unregister(this); }@Override public void afterPropertiesSet() throws Exception {eventPublisher.register(this); }@EventListenerpublic void onPluginEnable(PluginEnabledEvent pluginEnabledEvent) { log.error(pluginEnabledEvent.getPlugin().getKey()); }}Mb someone knows what is wrong.Thanks!
Can you provide more details about the problems you're having? What do you mean by "I can't use the plugin"?
It's disabled.
Well you need to check the logs and see what happened. Probably the problem is not related to the code above.
It looks like you're new here. Sign in or register to get started.