Prevent internal server error if empty custom field for channel (refs #17)
This commit is contained in:
@@ -24,7 +24,11 @@ from the plugin directory.
|
||||
|
||||
Restart Redmine, and you should see the plugin show up in the Plugins page.
|
||||
Under the configuration options, set the Mattermost API URL to the URL for an
|
||||
Incoming WebHook integration in your Mattermost account (see also the next two sections).
|
||||
Incoming WebHook integration in your Mattermost account and also set the Mattermost
|
||||
Channel to the channel's handle (be careful, this is not the channel's display name
|
||||
visible to users, you can find each channel's handle by navigating inside the channel
|
||||
and clicking the down-arrow and selecting view info). See also the next two sections
|
||||
for advanced and custom routing options.
|
||||
|
||||
## Customized Routing
|
||||
|
||||
|
||||
@@ -202,7 +202,8 @@ private
|
||||
Setting.plugin_redmine_mattermost[:channel],
|
||||
].find{|v| v.present?}
|
||||
|
||||
# Channel name '-' is reserved for NOT notifying
|
||||
# Channel name '-' or empty '' is reserved for NOT notifying
|
||||
return [] if val.to_s == ''
|
||||
return [] if val.to_s == '-'
|
||||
val.split(",")
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user