Skip to content

Commit c4b0509

Browse files
Fix a couple typos and revise sentence on new column serializer docs
[ci skip]
1 parent 1797e5b commit c4b0509

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

activerecord/lib/active_record/attribute_methods/serialization.rb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ module ClassMethods
6363
# ==== Choosing a serializer
6464
#
6565
# While any serialization format can be used, it is recommended to carefully
66-
# evaludate the properties of a serializer before using it, as migrating to
66+
# evaluate the properties of a serializer before using it, as migrating to
6767
# another format later on can be difficult.
6868
#
6969
# ===== Avoid accepting arbitrary types
@@ -72,9 +72,9 @@ module ClassMethods
7272
# only expected types will be serialized. For instance some serializer like
7373
# +Marshal+ or +YAML+ are capable of serializing almost any Ruby object.
7474
#
75-
# This can lead to unexpected types being serialized, and it it happens
76-
# that type serialization must remain backward and forward compatible as long
77-
# as some database record still contain these serialized types.
75+
# This can lead to unexpected types being serialized, and it is important
76+
# that type serialization remains backward and forward compatible as long
77+
# as some database records still contain these serialized types.
7878
#
7979
# class Address
8080
# def initialize(line, city, country)
@@ -116,13 +116,13 @@ module ClassMethods
116116
# serialize :address, coder: Address
117117
# end
118118
#
119-
# This patterns allow to be more deliberate about what is serialized, and
119+
# This pattern allows to be more deliberate about what is serialized, and
120120
# to evolve the format in a backward compatible way.
121121
#
122122
# ===== Ensure serialization stability
123123
#
124124
# Some serialization methods may accept some types they don't support by
125-
# silently casting them to another types. This can cause bugs when the
125+
# silently casting them to other types. This can cause bugs when the
126126
# data is deserialized.
127127
#
128128
# For instance the +JSON+ serializer provided in the standard library will

guides/source/configuring.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1275,7 +1275,7 @@ column.
12751275

12761276
`serialize` and `store` while allowing to use alternative serializer
12771277
implementations, use `YAML` by default, but it's not a very efficient format
1278-
and can be the source of security vulnerability if not carefully employeed.
1278+
and can be the source of security vulnerabilities if not carefully employed.
12791279
12801280
As such it is recommended to prefer stricter, more limited formats for database
12811281
serialization.

0 commit comments

Comments
 (0)