xmppify 0.0.23 → 0.0.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3582b17544b1bd1879179a5844686e882b42d5c5
4
- data.tar.gz: 3cd80ed67114ccee271bbf944022b25511c87a02
3
+ metadata.gz: 726261def4b164d4048a054584544c26a8cee606
4
+ data.tar.gz: f7d4451590f322f61569be03c9e1206ad87d9351
5
5
  SHA512:
6
- metadata.gz: 625102debe253e83ebe547ca56c1eadff868e2e592abaaac312bc98fa8f6c6ace4021b2c3f48dfd3557deeed02218cf2ab0d09494ee704471152c931c4245ab6
7
- data.tar.gz: 61fa42630c906bbb3a64241b77a774573e6fb952adcaa258ce42bece8861b42656c1ce9adb1bd77f3cdcafbeb87f88592252c21e4e328660e5d17dc2c3fd8226
6
+ metadata.gz: 0a957cfdc471c147098451baa6ce88d27b579e4d55452a9190de174fe65e041a52193e35fd93caf4e8bed107795889cdf7ece341a25b4b73a7fe8ea09c984d5c
7
+ data.tar.gz: db80d3a62b92ac34e8badea5277c26b4d23bcc2084a3610c4640969a95ded3b683fc96e47aaeae3229940ee361aa8c886c85817cbace5f4e27fc1aae9f11e8eb
@@ -7,7 +7,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
7
7
  @user.save
8
8
  xmpp_credentials = sign_in_as @user
9
9
  ap xmpp_credentials
10
- flash[:attacher] = attacher(xmpp_credentials)
10
+ flash[:attacher] = xmpp_credentials
11
11
  if @user.identities.find_by(provider:"github").nil?
12
12
  @user.identities.create(provider:"github",auth_token:oauth_data.info.github_auth_token,email:oauth_data.info.github_email)
13
13
  end
@@ -20,12 +20,4 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
20
20
  def sign_in_as(user)
21
21
  return user.connect
22
22
  end
23
-
24
- def attacher(xmpp_credentials)
25
- {
26
- jid: xmpp_credentials.jid,
27
- id: xmpp_credentials.sid,
28
- rid: xmpp_credentials.rid
29
- }
30
- end
31
23
  end
data/app/models/user.rb CHANGED
@@ -36,6 +36,6 @@ class User < ActiveRecord::Base
36
36
 
37
37
  def connect
38
38
  @jid, @sid, @rid = RubyBOSH.initialize_session("#{self.encrypted_data}@idlecampus.com", "#{ENV['DOORKEEPER_APP_SECRET']}", "http://idlecampus.com:5280/http-bind")
39
- return @jid, @sid, @rid
39
+ return {jid: @jid, id: @sid, rid: @rid }
40
40
  end
41
41
  end
@@ -1,3 +1,3 @@
1
1
  module Xmppify
2
- VERSION = "0.0.23"
2
+ VERSION = "0.0.24"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xmppify
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.23
4
+ version: 0.0.24
5
5
  platform: ruby
6
6
  authors:
7
7
  - Charlie