lib/dradis/plugins/content_service/issues.rb in dradis-plugins-3.6.0 vs lib/dradis/plugins/content_service/issues.rb in dradis-plugins-3.7.0
- old
+ new
@@ -17,12 +17,14 @@
cache_key = uuid.join('-')
return issue_cache[cache_key] if issue_cache.key?(cache_key)
# we inject the source Plugin and unique ID into the issue's text
- text << "\n\n#[plugin]#\n#{uuid[0]}\n"
- text << "\n\n#[plugin_id]#\n#{uuid[1]}\n"
+ plugin_details =
+ "\n\n#[plugin]#\n#{uuid[0]}\n" \
+ "\n\n#[plugin_id]#\n#{uuid[1]}\n"
+ text << plugin_details
issue = Issue.new(text: text) do |i|
i.author = default_author
i.node = issue_library
i.category = default_issue_category
@@ -33,10 +35,11 @@
else
try_rescue_from_length_validation(
model: issue,
field: :text,
text: text,
- msg: 'Error in create_issue()'
+ msg: 'Error in create_issue()',
+ tail: plugin_details
)
end
issue_cache.store(cache_key, issue)
end