@@ -584,17 +584,17 @@ def destroy!
584
584
end
585
585
586
586
# Returns an instance of the specified +klass+ with the attributes of the
587
- # current record. This is mostly useful in relation to single- table
588
- # inheritance structures where you want a subclass to appear as the
587
+ # current record. This is mostly useful in relation to single table
588
+ # inheritance (STI) structures where you want a subclass to appear as the
589
589
# superclass. This can be used along with record identification in
590
590
# Action Pack to allow, say, <tt>Client < Company</tt> to do something
591
591
# like render <tt>partial: @client.becomes(Company)</tt> to render that
592
592
# instance using the companies/company partial instead of clients/client.
593
593
#
594
594
# Note: The new instance will share a link to the same attributes as the original class.
595
- # Therefore the sti column value will still be the same.
595
+ # Therefore the STI column value will still be the same.
596
596
# Any change to the attributes on either instance will affect both instances.
597
- # If you want to change the sti column as well, use #becomes! instead.
597
+ # If you want to change the STI column as well, use #becomes! instead.
598
598
def becomes ( klass )
599
599
became = klass . allocate
600
600
@@ -609,11 +609,11 @@ def becomes(klass)
609
609
became
610
610
end
611
611
612
- # Wrapper around #becomes that also changes the instance's sti column value.
612
+ # Wrapper around #becomes that also changes the instance's STI column value.
613
613
# This is especially useful if you want to persist the changed class in your
614
614
# database.
615
615
#
616
- # Note: The old instance's sti column value will be changed too, as both objects
616
+ # Note: The old instance's STI column value will be changed too, as both objects
617
617
# share the same set of attributes.
618
618
def becomes! ( klass )
619
619
became = becomes ( klass )
0 commit comments