Skip to content

Commit

Permalink
Button overlay params and ticket_ids should be accessable from payloa…
Browse files Browse the repository at this point in the history
…d helper
  • Loading branch information
avinasha committed Nov 14, 2012
1 parent 1749809 commit 034e013
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 48 deletions.
1 change: 1 addition & 0 deletions Gemfile
Expand Up @@ -10,6 +10,7 @@ gem 'faraday'
gem 'faraday_middleware'
gem 'hashie'
gem 'haml'
gem 'mail'

# App Gems
gem 'tinder'
Expand Down
9 changes: 9 additions & 0 deletions Gemfile.lock
Expand Up @@ -37,10 +37,15 @@ GEM
json (1.7.5)
listen (0.5.3)
lumberjack (1.0.2)
mail (2.4.4)
i18n (>= 0.4.0)
mime-types (~> 1.16)
treetop (~> 1.4.8)
method_source (0.8.1)
mime-types (1.19)
multi_json (1.3.6)
multipart-post (1.1.5)
polyglot (0.3.3)
pry (0.9.10)
coderay (~> 1.0.5)
method_source (~> 0.8)
Expand Down Expand Up @@ -79,6 +84,9 @@ GEM
multi_json (~> 1.0)
multipart-post (~> 1.1)
twitter-stream (~> 0.1)
treetop (1.4.10)
polyglot
polyglot (>= 0.3.1)
twitter-stream (0.1.16)
eventmachine (>= 0.12.8)
http_parser.rb (~> 0.5.1)
Expand All @@ -97,6 +105,7 @@ DEPENDENCIES
guard-shotgun!
haml
hashie
mail
rack-test
rake
rspec
Expand Down
31 changes: 0 additions & 31 deletions apps/jira/config.yml

This file was deleted.

14 changes: 0 additions & 14 deletions apps/jira/jira.rb

This file was deleted.

7 changes: 4 additions & 3 deletions lib/base.rb
Expand Up @@ -247,9 +247,10 @@ def sanitize_log_value(value)


def pre_process_payload(raw)
raw = Hashie::Mash.new(raw).payload
return {} unless raw
result = Hashie::Mash.new({:raw => raw})
result = Hashie::Mash.new(raw)
raw = result.delete(:payload)
return result unless raw

if raw[:tickets]
result[:tickets] = []
raw[:tickets].each {|ticket| result[:tickets] << SupportBee::Ticket.new(auth, ticket) }
Expand Down

0 comments on commit 034e013

Please sign in to comment.