immortal 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. data/README.md +1 -0
  2. data/immortal.gemspec +1 -1
  3. data/lib/immortal.rb +1 -1
  4. metadata +3 -3
data/README.md CHANGED
@@ -44,4 +44,5 @@ If you want to improve immortal
44
44
 
45
45
  ## CHANGELOG
46
46
 
47
+ - 0.1.2 fix loading issue when the `deleted` column doesn't exist (or even the table)
47
48
  - 0.1.1 fix behavior with `has_many :through` associations
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "immortal"
6
- s.version = '0.1.1'
6
+ s.version = '0.1.2'
7
7
  s.platform = Gem::Platform::RUBY
8
8
  s.authors = ["Jordi Romero", "Saimon Moore"]
9
9
  s.email = ["jordi@jrom.net", "saimon@saimonmoore.net"]
@@ -60,7 +60,7 @@ module Immortal
60
60
  module InstanceMethods
61
61
  def self.included(base)
62
62
  base.class_eval do
63
- default_scope where(arel_table[:deleted].eq(nil).or(arel_table[:deleted].eq(false)))
63
+ default_scope where(arel_table[:deleted].eq(nil).or(arel_table[:deleted].eq(false))) if arel_table[:deleted]
64
64
  alias :mortal_destroy :destroy
65
65
  alias :destroy :immortal_destroy
66
66
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: immortal
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 31
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 1
10
- version: 0.1.1
9
+ - 2
10
+ version: 0.1.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Jordi Romero