easy_roles 0.4.2 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +3 -0
- data/Rakefile +1 -1
- data/easy_roles.gemspec +2 -2
- data/lib/easy_roles.rb +1 -1
- metadata +2 -2
data/README.rdoc
CHANGED
@@ -4,6 +4,9 @@ Simple rails gem for basic role authorization with ruby on rails.
|
|
4
4
|
|
5
5
|
== Changelog
|
6
6
|
|
7
|
+
=== 05 April 2010 - Version 0.4.2
|
8
|
+
Serialize method updated for Rails 3 compatibility. (Thanks to firebelly for pointing this out)
|
9
|
+
|
7
10
|
=== 03 February 2010 - Version 0.4.2
|
8
11
|
Fixed migration names
|
9
12
|
Does not allow duplicates to be added
|
data/Rakefile
CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
|
|
2
2
|
require 'rake'
|
3
3
|
require 'echoe'
|
4
4
|
|
5
|
-
Echoe.new('easy_roles', '0.
|
5
|
+
Echoe.new('easy_roles', '1.0.0') do |p|
|
6
6
|
p.description = "Easy role authorization in rails"
|
7
7
|
p.url = "http://github.com/platform45/easy_roles"
|
8
8
|
p.author = "Platform45"
|
data/easy_roles.gemspec
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{easy_roles}
|
5
|
-
s.version = "0.
|
5
|
+
s.version = "1.0.0"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Platform45"]
|
9
|
-
s.date = %q{2010-
|
9
|
+
s.date = %q{2010-04-05}
|
10
10
|
s.description = %q{Easy role authorization in rails}
|
11
11
|
s.email = %q{ryan@platform45.com}
|
12
12
|
s.extra_rdoc_files = ["README.rdoc", "lib/easy_roles.rb"]
|
data/lib/easy_roles.rb
CHANGED
@@ -11,7 +11,7 @@ module EasyRoles
|
|
11
11
|
|
12
12
|
if options[:method] == :serialize
|
13
13
|
serialize name.to_sym, Array
|
14
|
-
before_validation_on_create :make_default_roles
|
14
|
+
respond_to?(:before_validation_on_create) ? before_validation_on_create(:make_default_roles) : before_validation(:make_default_roles, :on => :create)
|
15
15
|
|
16
16
|
class_eval <<-EOC
|
17
17
|
def has_role?(role)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: easy_roles
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Platform45
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2010-
|
12
|
+
date: 2010-04-05 00:00:00 +02:00
|
13
13
|
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|