nagybence-railhead_autouser 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -16,7 +16,7 @@ end
16
16
 
17
17
  class RailheadAutoUserSweeper < ActionController::Caching::Sweeper
18
18
  def before_save(record)
19
- record.user_id = current_user.id if current_user and record.respond_to?(:user_id) and record.new_record?
19
+ record.user_id = current_user.id if current_user and record.respond_to?(:user_id) and record.new_record? and record.user_id.nil?
20
20
  end
21
21
  end
22
22
 
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "railhead_autouser"
3
- s.version = "0.1.1"
3
+ s.version = "0.1.2"
4
4
  s.date = "2009-01-28"
5
5
  s.summary = "RailheadAutoUser is a Ruby on Rails plugin that automatically adds current_user to models."
6
6
  s.email = "nagybence@tipogral.hu"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nagybence-railhead_autouser
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bence Nagy