mumukit-login 7.4.2 → 7.4.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9936c36470aad69a4573c77067305f4f1cc689657f3e853cad2c67fa9cf655db
4
- data.tar.gz: 13566888f54e440dd75d6122262aaf66cd8e4e817d35433db9d1a62565172b94
3
+ metadata.gz: fd902bc892d6881295171b8ddd9502f0ec70da727ade976edb0d399556196f54
4
+ data.tar.gz: 0e82d8fb0dce8e82ed39ddc2793722446a3f2e10c39f6e021bb55a3cd5004470
5
5
  SHA512:
6
- metadata.gz: 416fd94bf5d2344ea837a8edca52ef9e023b72e4b7b67af45a70c5bd6d4b95a0d456d5f0260c207a0a41a2ee714569998ebdb117da1816c6d6064d09bedcf39d
7
- data.tar.gz: 8f7bd5f3152b4624de431567f937facb9a57cdb2c7fd5782c970ad4e8db034e9c11671cb000a8e9361f25542b6a1c7f609664b65eccdedca12eaef7fa00fc657
6
+ metadata.gz: b281525c1d8d326de527da48a88440dd3427c43440b8a8306a22cb9701d741a464e610520143999a87193d928bdf41ba826b384e07e8223da590fc35f6618f57
7
+ data.tar.gz: dd697f2ec90429d7d589d8d5585bdfbd7d2ac46789ec387c961fc381b231fea667c7036fb63eadd8b6e1bbf70f3603dbf0ed860b6c265f12fae3a35b8ca5c3f5
@@ -11,10 +11,14 @@ module Mumukit::Login::Profile
11
11
  social_id: omniauth.uid,
12
12
  email: omniauth.info.email,
13
13
  uid: generate_uid(omniauth),
14
- image_url: omniauth.info.image
14
+ image_url: image_url(omniauth.info.image)
15
15
  }.compact
16
16
  end
17
17
 
18
+ def self.image_url(url)
19
+ url if url.try { size <= 255 }
20
+ end
21
+
18
22
  def self.generate_uid(omniauth)
19
23
  Mumukit::Login::Provider.parse_login_provider(omniauth.provider).uid_for_profile(omniauth)
20
24
  end
@@ -1,5 +1,5 @@
1
1
  module Mumukit
2
2
  module Login
3
- VERSION = '7.4.2'
3
+ VERSION = '7.4.3'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mumukit-login
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.4.2
4
+ version: 7.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Franco Leonardo Bulgarelli
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-02 00:00:00.000000000 Z
11
+ date: 2020-10-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler