Class: CollavreGithub::PrTopicLinkParser
- Inherits:
-
Object
- Object
- CollavreGithub::PrTopicLinkParser
- Defined in:
- app/services/collavre_github/pr_topic_link_parser.rb
Constant Summary collapse
- TOPIC_RE =
%r{/creatives/\d+/topics/(\d+)}.freeze
Class Method Summary collapse
Class Method Details
.call(body) ⇒ Object
5 6 7 8 9 |
# File 'app/services/collavre_github/pr_topic_link_parser.rb', line 5 def self.call(body) return nil if body.blank? m = body.match(TOPIC_RE) m && m[1].to_i end |