kkorach-acts_as_revisable 0.9.7 → 0.9.8

Sign up to get free protection for your applications and to get access to all the features.
@@ -389,6 +389,10 @@ module FatJam
389
389
  key = self.read_attribute(self.class.primary_key)
390
390
  self.class.revisable_shared_objects.delete(key)
391
391
  end
392
+
393
+ def previous_revision
394
+ revisions.first
395
+ end
392
396
 
393
397
  module ClassMethods
394
398
  # acts_as_revisable's override for with_scope that allows for
@@ -33,22 +33,6 @@ module FatJam
33
33
  self.send(:include, Revision)
34
34
  end
35
35
 
36
- # This +acts_as+ extension provides for making a Single Table Inheritance model the
37
- # revisable model in an acts_as_revisable pair.
38
- def acts_as_revisable_sti(*args, &block)
39
- revisable_shared_setup(args, block)
40
- self.send(:extend, Common::ClassMethods)
41
- self.send(:extend, Revisable::ClassMethods)
42
- end
43
-
44
- # This +acts_as+ extension provides for making a Single Table Inheritance model the
45
- # revision model in an acts_as_revisable pair.
46
- def acts_as_revision_sti(*args, &block)
47
- revisable_shared_setup(args, block)
48
- self.send(:extend, Common::ClassMethods)
49
- self.send(:extend, Revision::ClassMethods)
50
- end
51
-
52
36
  private
53
37
  # Performs the setup needed for both kinds of acts_as_revisable
54
38
  # models.
@@ -3,7 +3,7 @@ module FatJam #:nodoc:
3
3
  module VERSION #:nodoc:
4
4
  MAJOR = 0
5
5
  MINOR = 9
6
- TINY = 7
6
+ TINY = 8
7
7
 
8
8
  STRING = [MAJOR, MINOR, TINY].join('.')
9
9
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kkorach-acts_as_revisable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.7
4
+ version: 0.9.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rich Cavanaugh of JamLab, LLC.
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2008-08-13 00:00:00 -07:00
13
+ date: 2009-01-11 00:00:00 -08:00
14
14
  default_executable:
15
15
  dependencies: []
16
16