glib-web 0.4.3 → 0.4.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: 38b5751f1b2684f0d68bacb791098fc4aab5ab6b42cb25f1891a1f27bbdbbc8f
4
- data.tar.gz: eed1f00a5ccd846f36d7291620f45f8702a63f80ffe8b94364243a5f1ce3cb55
3
+ metadata.gz: 36ac8042a2934608affdfa3ac546ca2efd6caff2f03eb2a1a02d7c9e3c145443
4
+ data.tar.gz: dbeaafdbf9ae36aeb6419cdba60c7676489eef6830076d8a9c84cdb26c98ef12
5
5
  SHA512:
6
- metadata.gz: a464dbf43a08c5f9b131c5e18b48bda98d40ef29e0298827b78e901f667df0901f227be11809feb39be6d55aa1b9b09133cfa119d06829f5dd663a569ef2e6eb
7
- data.tar.gz: ca3b4567e5344a9d057c66d772aded64ba86b810d650837b1581eb40a3a981eed7e646c58e5915964f3a612088b0451a8cd490542e51d288bd5e4f30ba5d28a3
6
+ metadata.gz: 3b528ad5eeb7613ae09e83f31e74951b7b40e64424e5086d75022039f66dc0a44624e4dc9818eddd7a205afe97d74ba298a4072ae0a568ea5b29f8ae28245c0f
7
+ data.tar.gz: eda842d4c68a7c74b9d3d59c663c4725eae8c7342b5dc9f7bdacbb9769b26850ce7a6f8739316047265c031d8936ce2edc98887619e2c9c9475ab42876b90edb
@@ -1,3 +1,5 @@
1
+ require 'pundit'
2
+
1
3
  module Glib::Auth
2
4
  module Policy
3
5
  extend ActiveSupport::Concern
@@ -6,7 +8,7 @@ module Glib::Auth
6
8
  include Pundit
7
9
  include Overrides
8
10
  extend ClassMethods
9
-
11
+
10
12
  # TODO: Ultimately we want to uncomment this line, but:
11
13
  # - Need to be able to set aside some time to run rspec tests to ensure nothing gets broken
12
14
  # - Need to find a solution where we can reuse a single public policy
@@ -53,7 +55,7 @@ module Glib::Auth
53
55
  end
54
56
 
55
57
 
56
-
58
+
57
59
  module ClassMethods
58
60
  # Inspired from https://github.com/ryanb/cancan/wiki/Non-RESTful-Controllers
59
61
  public
@@ -63,7 +65,7 @@ module Glib::Auth
63
65
 
64
66
  self.before_action(options.slice(:only, :except, :if, :unless)) do |controller|
65
67
  resource_name ||= resource_name_from_controller
66
-
68
+
67
69
  if !(resource_key = options[:class]).nil?
68
70
  resource = case resource_key
69
71
  when false
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glib-web
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.3
4
+ version: 0.4.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''