Skip to content

Commit

Permalink
#1195 glogin 0.14.1
Browse files Browse the repository at this point in the history
  • Loading branch information
yegor256 committed Jan 22, 2024
1 parent 74024bb commit 8dda78e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

source 'https://rubygems.org'

gem 'glogin', '0.14.0'
gem 'glogin', '0.14.1'
gem 'haml', '6.3.0'
gem 'iri', '0.8.0'
gem 'loog', '0.5.1'
Expand Down
4 changes: 2 additions & 2 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ GEM
faraday_middleware (1.2.0)
faraday (~> 1.0)
ffi (1.16.3)
glogin (0.14.0)
glogin (0.14.1)
base58 (>= 0.2)
openssl (>= 2.0)
haml (6.3.0)
Expand Down Expand Up @@ -271,7 +271,7 @@ PLATFORMS
x86_64-linux

DEPENDENCIES
glogin (= 0.14.0)
glogin (= 0.14.1)
haml (= 6.3.0)
iri (= 0.8.0)
loog (= 0.5.1)
Expand Down
5 changes: 2 additions & 3 deletions front/front_login.rb
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,12 @@
code = params[:code]
error(400) if code.nil?
json = settings.glogin.user(code)
identity = json['login']
cookies[:identity] = GLogin::Cookie::Open.new(
{ id: identity },
json,
settings.config['github']['encryption_secret'],
context
).to_s
flash(iri.cut('/'), 'You have been logged in')
flash(iri.cut('/'), "@#{json['login']} has been logged in")
end

get '/logout' do
Expand Down

0 comments on commit 8dda78e

Please sign in to comment.