Commit 83584cc
committed
Handle string field names in
Previously `respond_to?` assumed it was given a symbol argument, so it
directly checked for that argument in the fields, which are force-keyed
as symbols. If you passed it a string argument, it wouldn't find the
corresponding field, impying it didn't respond to such a method.
Now, the argument is explicitly cast to a symbol before checking if such
a field exists, supporting checking `respond_to?` with both argument
types.CustomFieldList#respond_to?
1 parent dd693a3 commit 83584cc
3 files changed
Lines changed: 9 additions & 2 deletions
File tree
- lib/netsuite/records
- spec/netsuite/records
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
64 | | - | |
| 63 | + | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
273 | 273 | | |
274 | 274 | | |
275 | 275 | | |
| 276 | + | |
276 | 277 | | |
| 278 | + | |
277 | 279 | | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
278 | 284 | | |
279 | 285 | | |
280 | 286 | | |
| |||
0 commit comments