authralia 0.0.2 → 0.0.4

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: 2992e694d931ea98652a6d624793d46239fcf1af73bb5d72e791eb487c994d62
4
- data.tar.gz: c0d0706e07e39dea8f666670a57ac3b790d0c48916554389f4f04c9485e13b77
3
+ metadata.gz: 4228a4ab22a4799ddffa6db3376677d8d65a3652e71a9ffbfa2a55170cb655ca
4
+ data.tar.gz: 9a316a3be66fbfcd320d81a1e7eb40b033f6530f6677ec4cc2023f694d037f89
5
5
  SHA512:
6
- metadata.gz: 4aa9d6497e33ebc8999bef5f0387054ed8e72282e4b538d2748a785f6b498aa0480d48aff380b43e40102738950f364edfcdeb312901e9beecea50f331cde9c5
7
- data.tar.gz: 8d062d8f68e62577d4c6f596396a3d4514ae7333698bdc7328c3771d2d6c7952a088effa35d7fca816a98f02a1b396301f089590780925ab42e3331fae767a34
6
+ metadata.gz: 95c7e15a297c0f3362577fd585aa04ac1b6bb12b19ff8766ed06ee867bf21b98d70199a26e27d328ee037f18ec03401d83d78c0cf72f26db395e5fe8ac858009
7
+ data.tar.gz: 6c7624a0a9dc224cc51417f98a59a80ff335ae4b789245b2dd67c99b8b6e736f6cbb88e6a7d9b9eaf4333afc2550d13264f9fc1bcaa3d5f9898883008ac1dd2b
@@ -1,6 +1,6 @@
1
1
  module Authralia
2
2
  module Authenticate
3
- class Base < ServiceObject::Base
3
+ class Base < ::SerpisObjek::Base
4
4
  end
5
5
  end
6
6
  end
@@ -1,6 +1,6 @@
1
1
  module Authralia
2
2
  module AuthenticatedSession
3
- class Base < ServiceObject::Base
3
+ class Base < ::SerpisObjek::Base
4
4
  protected
5
5
 
6
6
  def extract_resource_identifier(session_identifier)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: authralia
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gilang Mugni Respaty
@@ -38,7 +38,8 @@ dependencies:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
- description: A authentication dedicated to Mike Tyson
41
+ description: An authentication dedicated to Mike Tyson based on his favorite place,
42
+ Australia!
42
43
  email: gilmoregarland@gmail.com
43
44
  executables: []
44
45
  extensions: []
@@ -56,7 +57,6 @@ files:
56
57
  - lib/authralia.rb
57
58
  - lib/controllers/helpers.rb
58
59
  - lib/models/thydney_the_protector.rb
59
- - lib/wow_authralia.rb
60
60
  homepage: https://rubygems.org/gems/hola
61
61
  licenses:
62
62
  - MIT
data/lib/wow_authralia.rb DELETED
@@ -1,56 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # when Mike Tyson marvel at Australia's beautiful view
4
-
5
- # TODO: use warden
6
- # http://railscasts.com/episodes/305-authentication-with-warden?view=asciicast
7
- module WowAuthralia
8
- def self.configuration
9
- @configuration ||= Configuration.new
10
- end
11
-
12
- def self.configure
13
- yield configuration
14
- end
15
- end
16
-
17
-
18
- class WowAuthralia::Configuration
19
- include ActiveSupport::Configurable
20
-
21
- config_accessor(:single_active_session) { false }
22
- config_accessor(:expires_in) { 1.hour }
23
- config_accessor(:resource_class_names) { [] }
24
- end
25
-
26
- ActiveSupport.on_load(:action_controller_base) do
27
- include WowAuthralia::Controllers::Helpers
28
- end
29
-
30
- ActiveSupport.on_load(:active_record) do
31
- include WowAuthralia::Models::ThydneyTheProtector
32
- end
33
-
34
- module ActionDispatch::Routing
35
- class Mapper
36
- def when_authticanted(resource_class_name, &block)
37
- constraint = lambda do |request|
38
- request.session[resource_class_name.underscore].present?
39
- end
40
-
41
- constraints(constraint) do
42
- yield
43
- end
44
- end
45
-
46
- def when_unauthticanted(resource_class_name, &block)
47
- constraint = lambda do |request|
48
- request.session[resource_class_name.underscore].blank?
49
- end
50
-
51
- constraints(constraint) do
52
- yield
53
- end
54
- end
55
- end
56
- end